diff --git a/CHANGELOG.md b/CHANGELOG.md index 5698832ed4..66d1c73b32 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,10 @@ # Changelog +## v0.5.5 + +This is a hot fix release, the detail about this fix will be revealed later. +Please upgrade your node to this version if your node is exposed to the public network via p2p. + ## v0.5.4 This is a minor release for opBNB Mainnet and Testnet. diff --git a/crypto/crypto.go b/crypto/crypto.go index 4d69768bc8..f3e30de4cc 100644 --- a/crypto/crypto.go +++ b/crypto/crypto.go @@ -197,6 +197,9 @@ func UnmarshalPubkey(pub []byte) (*ecdsa.PublicKey, error) { if x == nil { return nil, errInvalidPubkey } + if !S256().IsOnCurve(x, y) { + return nil, errInvalidPubkey + } return &ecdsa.PublicKey{Curve: S256(), X: x, Y: y}, nil }