Page MenuHomePhabricator

Revert "add flags to VerifySignature and sigcache"
ClosedPublic

Authored by markblundeberg on Jun 7 2019, 04:35.

Details

Summary

This reverts D2373, which was only done in the first place so that a
pre-activation 64-byte ECDSA signature could not fill the cache to
masquerade as a Schnorr signature post-activation. Now that the
upgrade is past and enable_schnorr flag is gone, this extra technical
complication is pointless (and it is unlikely to ever be useful again).

Depends on D3332

Test Plan

make check

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

jasonbcox added inline comments.
src/script/sigcache.cpp
53 ↗(On Diff #9235)

I realize this ordering is going back to what it used to be. But that begs the question why it was changed in the first place?

src/script/sigcache.cpp
53 ↗(On Diff #9235)

IIRC I changed it in order to match the order of its caller, VerifySignature. Perhaps we can keep that order, just take out flags.

An alternative order that would also make sense is hash,pubkey,sig, which would match order of hashing.

This is correct as long as we "pretend" schnorr always was activated.

This revision is now accepted and ready to land.Jun 12 2019, 17:15