diff --git a/contracts/Secp256r1.sol b/contracts/Secp256r1.sol index 13d74ad..24bccfc 100644 --- a/contracts/Secp256r1.sol +++ b/contracts/Secp256r1.sol @@ -24,7 +24,7 @@ contract Secp256r1 { function Verify(uint X, uint Y, uint r, uint s, bytes memory input) public pure returns (bool) { - if (r >= nn || s >= nn) { + if (r==0 || s==0 ||r >= nn || s >= nn) { return false; } @@ -321,4 +321,4 @@ contract Secp256r1 { return uint(t1); } -} \ No newline at end of file +}