revm_specification/
eip2.rs

1use primitives::U256;
2
3/// The order of the secp256k1 curve, divided by two.
4///
5/// Signatures that should be checked according to EIP-2 should have an S value less than or equal to this:
6///
7/// `57896044618658097711785492504343953926418782139537452191302581570759080747168`
8pub const SECP256K1N_HALF: U256 = U256::from_be_bytes([
9    0x7F, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF,
10    0x5D, 0x57, 0x6E, 0x73, 0x57, 0xA4, 0x50, 0x1D, 0xDF, 0xE9, 0x2F, 0x46, 0x68, 0x1B, 0x20, 0xA0,
11]);