GHSA-xrrq-rrgq-h89w — static-alloc
Fix: 197g/static-alloc#82GHSA-xrrq-rrgq-h89w is a security vulnerability in static-alloc. A fix is available for static-alloc — see the affected versions and patch details below.
static-alloc vulnerability leads to uninitialized read after allocating MemBump
Real-World Exposure
static-allocReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects crates.io packages — download data is not available via public APIs for these ecosystems.
Description
The affected function, MemBump::new(), would allocate memory without initializing it. Subsequently calling the created value's various allocmethods would then read and write the start of that memory as a Cell which isundefined behavior. Instead, it should zero initialize the start of the allocated memory.
For instance, some values could violate the internal invariants of the type and cause an assertion failure. Nevertheless, no deterministic read is known tocause further uninitialized memory to be exposed.
Affected downstream users that can not upgrade are advised to call MemBump::reset immediately after allocation to manually perform the missing write of the counter best-as-possible.
The flaw was corrected in commit d8d6a7d096d3aaafd963b356a8f1bbd8d26fd967 by zeroing the Cell at the start of the allocated memory.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🦀crates.io | static-alloc | ≥ 0.2.2&&< 0.2.6 | 0.2.6cargo update -p static-alloc --precise 0.2.6 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for static-alloc, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update static-alloc to 0.2.6 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-xrrq-rrgq-h89w is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
How O3 protects you
O3 Security's impact-aware SCA analyses which vulnerable code paths your application actually calls, so a match like GHSA-xrrq-rrgq-h89w can be triaged on real exposure rather than presence alone.
Tailored to GHSA-xrrq-rrgq-h89w. Runtime protection reduces exposure until a permanent patch is applied and verified — it complements patching, it doesn't replace it.
Frequently Asked Questions
Is GHSA-xrrq-rrgq-h89w in your dependencies?
O3 Security finds GHSA-xrrq-rrgq-h89w across crates.io dependencies, including transitive ones, and its impact-aware SCA ranks findings by whether your code actually calls the vulnerable path.