Page MenuHomePhabricator

Add test for CheckSignatureEncoding to verify low S is checked properly.
ClosedPublic

Authored by deadalnix on Jul 15 2018, 22:55.

Details

Summary

Increase the unit test coverage for CheckSignatureEncoding.

Depends on D1567

Test Plan
make check

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

jasonbcox added a subscriber: jasonbcox.

Accepted, with feedback on a comment

src/test/sigencoding_tests.cpp
100 ↗(On Diff #4314)

Since CheckSignatureEncodingWithSigHashType checks more than just the correct forkId, I think this comment should be more along the lines of:
// Minimal signature is valid with any flags

This revision is now accepted and ready to land.Jul 17 2018, 17:56
src/test/sigencoding_tests.cpp
100 ↗(On Diff #4314)

That comment would be incorrect because depending on forkid enforcement, and forkid flag, it may be invalid.

This revision was automatically updated to reflect the committed changes.