🛡️ CVE-2023-44273 — gnark-crypto
Description
gnark-crypto doesn't range check input values during ECDSA and EdDSA signature deserialization
Impact
During deserialization of ECDSA and EdDSA signatures gnark-crypto did not check that the values are in the range [1, n-1] with n being the corresponding modulus (either base field modulus in case of R in EdDSA, and scalar field modulus in case of s,r in ECDSA and s in EdDSA). As this also allowed zero inputs, then it was possible to craft a signature which lead to null pointer dereference, leading to denial-of-service of an application. This also enabled weak signature malleability when the users assumed uniqueness of the serialized signatures (but not the underlying modulo reduced values).
We are not aware of any users impacted by the bug. The implemented signature schemes in gnark-crypto complement the in-circuit versions in gnark, allowing to have end-to-end tests.
Patches
The issue was patched in PR #449. The fix returns an error during deserialization if the values do not belong to the ranges [1, n-1].
The fix is included in release v0.12.0 and upwards.
Workarounds
Users can manually validate the inputs to be in corresponding ranges when using serialized signatures (or digests of them) as unique keys.
To address the denial-of-service, the users can install hook to recover panics and recover
Resources
- [Verichains advisory](https://github.com/advisories/GHSA-9xfq-8j3r-xp5g) for signature malleability.
- Fix https://github.com/Consensys/gnark-crypto/pull/449
- [Go blog post "Defer, Panic, and Recover"](https://go.dev/blog/defer-panic-and-recover)
- [gnark v0.12.0](https://github.com/Consensys/gnark-crypto/releases/tag/v0.12.0)
Acknowledgement
Lack of range checks leading to signature malleability was reported by [Verichains](https://www.verichains.io/).
How this vulnerability can be exploited
This issue can be reached over the network, attack complexity is low, an attacker needs no privileges on the target. No user interaction is required. The scope is unchanged, so the impact stays within the vulnerable component. Rated impact: confidentiality high, integrity high, availability high.
Weakness class
CVE-2023-44273 is classified as CWE-502: Deserialization of Untrusted Data. Serialised data from an untrusted source is reconstructed into objects, which can trigger code during the process.
Affected software
CVE-2023-44273 is recorded against 2 packages.
- github.com/consensys/gnark-crypto
- gnark-crypto (fixed in 0.12.0)
Timeline and source
Published on 28 September 2023 and last revised on 3 March 2026. No public exploit is currently recorded for this entry. A vendor advisory or fix has been published. Record sourced from NVD.
References
nvd.nist.gov (Advisory)
github.com (Web)
github.com (Package)
github.com (Web)
github.com (Web)
verichains.io (Web)
Details
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Affected Packages
| Software | From version | Fixed in |
|---|---|---|
| github.com/consensys/gnark-crypto | — | — |
| gnark-crypto | — | 0.12.0 |
References
Similar Threats
- Unknown GO-2025-4087
- High GHSA-fj2x-735w-74vq
- Unknown GO-2023-2101
- Low GHSA-pffg-92cg-xf5c
More CVE 2023 advisories
Browse all of CVE 2023 in the advisory index.
Exploit Protection
Are you running gnark-crypto?
CVE-2023-44273 carries CVSS 9.8 Critical rating. BotEraser checks your installation against this and other known CVE records, and blocks IPs associated with exploit activity.
Check My Site For CVE-2023-44273 →No credit card required · Results in minutes
ⓘ Data Notice: The information presented above has been compiled from publicly available internet sources. Boteraser aggregates this data solely for informational purposes and does not independently classify, evaluate, or endorse any findings about the vulnerabilities listed. The accuracy and completeness of this information is the sole responsibility of the original publishers. Boteraser and its operators accept no liability for any decisions made based on this data.