Skip to main content

Boteraser | Website and Server Security Solutions

🛡️ GHSA-rjjm-x32p-m3f7 — gnark

🟢 CVSS 2.0 — Low ✅ No Known Exploit OSV
2.0
CVSS Score
0 Low4 Medium7 High9 Critical10

Description

gnark's range checker gadget allows wider inputs up to word alignment

Impact

gnark provides a gadget in the standard library to allow optimized checking of the bitwidth of the inputs. The gadget works by constructing a fixed lookup table containing all valid entries, partitioning the input and checking that all parts are inside the lookup table. The range checker gadget did not take into account that the highest partition may be less than the width limit, allowing the inputs to be up to 16 bits wider than checked.

Range checking gadget is extensively used in field emulation. Users using any dependant gadget (ECDSA verification, proof recursion etc.) is impacted.

We consider the impact of the vulnerability being low as the number of attacker-modifiable bits is significantly smaller compared to the bit-width of scalar field modulus and it won't be possible to construct inputs which would allow to overflow the scalar field.

Patches

The issue has been patched in the stable branch of gnark.

Due to low severity of the issue no emergency release will be issued and we follow the existing release plan. Versions v0.9.2 and higher are patched.

Workarounds

We consider the issue very hard to exploit and do not recommend manual remediation. However, it is possible to perform manual bit decomposition using std/math/bits gadget.

References

Initial issue https://github.com/Consensys/gnark/issues/897

Acknowledgement

The issue was reported by [@ultrainstinct30](https://github.com/ultrainstinct30).

How this vulnerability can be exploited

This issue can be reached with local access to the system, attack complexity is high, an attacker needs no privileges on the target. No user interaction is required. The scope is changed, meaning a successful attack can affect components beyond the vulnerable one. Rated impact: confidentiality none, integrity low, availability none.

Affected software

GHSA-rjjm-x32p-m3f7 is recorded against 1 package.

  • github.com/consensys/gnark

Timeline and source

Published on 12 November 2023 and last revised on 15 November 2023. No public exploit is currently recorded for this entry. Record sourced from OSV.

References

github.com (Web)
github.com (Web)
github.com (Web)
github.com (Package)

Details

Severity LOW
CVSS Score 2.0
CVSS Vector CVSS:3.1/AV:L/AC:H/PR:N/UI:N/S:C/C:N/I:L/A:N
CWE N/A
Public Exploit ✅ No
Source OSV
Published 2023-11-12
Updated 2026-08-20
Modified 2023-11-15
Fix URL N/A

Affected Packages

Software From version Fixed in
github.com/consensys/gnark

Similar Threats

Free Vulnerability Check

Is your site affected by GHSA-rjjm-x32p-m3f7?

BotEraser helps you identify potentially vulnerable plugins and themes by checking your installation against GHSA-rjjm-x32p-m3f7 and other known CVE records.

Scan My Site Free →

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.