Skip to content

Commit

Permalink
Merge dashpay#657: Fix a nit in the recovery tests
Browse files Browse the repository at this point in the history
b64a2e2 Fix a nit in the recovery tests (Elichai Turkel)

Pull request description:

  this signature is only valid under recid 1 not 0.

  Source: https://github.com/bitcoin-core/secp256k1/blob/master/src/modules/recovery/tests_impl.h#L247
  (it passes only when the sig is parsed with recid 1)

ACKs for top commit:
  real-or-random:
    ACK b64a2e2 I only looked at the diff
  jonasnick:
    ACK b64a2e2 read the code

Tree-SHA512: 8e6744fe87c4078181dd1b334641784bf4fee37eb87346ecf8149482a9ea2c321bbe068e6a9199d836430b54b73848d94473a9aa6b59b4a68921a6321f449736
  • Loading branch information
jonasnick committed Aug 22, 2019
2 parents e028aa3 + b64a2e2 commit e729cc7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/modules/recovery/tests_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ void test_ecdsa_recovery_edge_cases(void) {
};
const unsigned char sig64[64] = {
/* Generated by signing the above message with nonce 'This is the nonce we will use...'
* and secret key 0 (which is not valid), resulting in recid 0. */
* and secret key 0 (which is not valid), resulting in recid 1. */
0x67, 0xCB, 0x28, 0x5F, 0x9C, 0xD1, 0x94, 0xE8,
0x40, 0xD6, 0x29, 0x39, 0x7A, 0xF5, 0x56, 0x96,
0x62, 0xFD, 0xE4, 0x46, 0x49, 0x99, 0x59, 0x63,
Expand Down

0 comments on commit e729cc7

Please sign in to comment.