OpenZeppelin Contracts ECDSA Compact Signature Malleability
CVE-2022-35961 is a signature-malleability flaw in the single-bytes-argument overloads of OpenZeppelin Contracts ECDSA.recover and ECDSA.tryRecover. The affected functions accept both conventional 65-byte ECDSA signatures and EIP-2098 compact signatures. The same valid signature can therefore be represented in alternate encodings that recover the same signer. Contracts that enforce signature replay or reuse protection by recording the raw signature bytes, rather than the signed message digest or a validated nonce, can treat the alternate encoding as a new signature.
What it means and what to do now: patch path, interim mitigations, and the assume-compromise checklist.
What an attacker gets, and what they’ve been doing with it.
An attacker who obtains or observes a signature already accepted by an affected contract can resubmit the same authorization in an alternative signature encoding and bypass raw-signature-based replay protection. This can permit repeated execution of the action authorized by the signature, potentially resulting in unauthorized repeated transfers, approvals, claims, or other signed operations.
If you can’t patch tonight, do this now.
Do not implement replay prevention by storing or comparing raw signature bytes. Bind authorizations to a unique signed message hash and a validated nonce, and mark the nonce or message authorization as consumed. Where applicable, avoid the affected single-bytes overloads and use the overloads accepting separate signature components while enforcing canonical handling in application logic.
Patch, then assume compromise.
Upgrade OpenZeppelin Contracts or Contracts Upgradeable to version 4.7.3 or later, which patches the issue.
No public exploits tracked yet. Mallory keeps watching.
Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.
2 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.