We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 27cc553 commit 440e714Copy full SHA for 440e714
libevm/precompiles/p256verify/p256verify.go
@@ -79,10 +79,11 @@ func (in *input) verify() bool {
79
func (in *input) pubkey() (*ecdsa.PublicKey, bool) {
80
x := in.bigWord(xPos)
81
y := in.bigWord(yPos)
82
- if x.Sign() == 0 && y.Sign() == 0 {
83
- return nil, false
84
- }
85
+ // There is no need to explicitly check for the point at infinity because
+ // [elliptic.Curve] documentation states that it's not on the curve and the
+ // check would therefore be performed twice.
86
+ // See https://cs.opensource.google/go/go/+/refs/tags/go1.24.3:src/crypto/elliptic/nistec.go;l=132
87
curve := elliptic.P256()
88
if !curve.IsOnCurve(x, y) {
89
return nil, false
0 commit comments