Tim Ruffing 0ba2b94551
Merge bitcoin-core/secp256k1#1373: Add invariant checking for scalars
d23da6d55714271c720fee58fbff5e5ef2fe193f use secp256k1_scalar_verify checks (stratospher)
c7d0454932b42a9728b55033c94e000b1dbbb6f2 add verification for scalars (stratospher)
ad152151b06a40aaf6cd90561356ff451996455d update max scalar in scalar_cmov_test and fix schnorrsig_verify exhaustive test (stratospher)

Pull request description:

  From #1360. This PR:
  1. adds `secp256k1_scalar_verify` to make sure scalars are reduced mod the group order in VERIFY mode
  2. uses `secp256k1_scalar_verify` in all the scalar functions except `secp256k1_scalar_clear`, `secp256k1_scalar_reduce_512`, `secp256k1_scalar_mul_512` and `secp256k1_scalar_*_var` functions in `scalar_low_impl.h`

ACKs for top commit:
  real-or-random:
    utACK d23da6d55714271c720fee58fbff5e5ef2fe193f
  theStack:
    Code-review ACK d23da6d55714271c720fee58fbff5e5ef2fe193f

Tree-SHA512: a371b319d948198c4038d35c9ea58f4b94de4dc312215e2b78a323c2acd4ae1355d97935c558b388774832d6d0058b97ff8ca50c3aab40b9ede5307760d0a505
2023-08-18 11:44:17 +02:00
..
2022-11-07 16:37:24 -05:00
2023-06-20 11:31:58 -04:00
2021-08-20 11:11:26 -04:00
2021-08-20 11:11:26 -04:00
2023-07-03 17:05:55 +02:00
2023-07-03 17:05:55 +02:00
2023-08-16 17:39:25 +05:30
2023-07-28 13:05:04 +02:00
2023-07-24 13:14:23 +01:00
2022-03-25 11:32:14 +01:00
2022-11-07 16:37:24 -05:00
2022-11-07 16:37:24 -05:00
2023-02-28 15:54:00 -05:00
2023-02-28 15:54:00 -05:00
2021-12-18 16:12:34 -05:00
2020-12-18 00:24:22 +02:00
2020-12-18 00:24:22 +02:00
2020-12-18 00:24:22 +02:00
2023-07-27 14:03:59 +05:30
2023-07-25 20:37:46 +00:00