Your RSA-2048 keys break in 2030. Find every one of them before attackers do.
🦀
🦀 crates.io
Not in CISA KEV
HIGH severity

GHSA-vcw4-8ph6-7vw8

HIGHFix: SergioBenitez/Rocket@b53a906

GHSA-vcw4-8ph6-7vw8 is a high-severity (CVSS 7.3) Use After Free vulnerability in rocket. 1 public exploit reference exists, so weaponization risk is real. O3 Security confirms whether GHSA-vcw4-8ph6-7vw8 is actually reachable in your code before you act, and blocks exploitation at runtime until you patch.

Use after free in Rocket

Also known asCVE-2021-29935RUSTSEC-2021-0044
Published
Aug 25, 2021
Updated
Nov 8, 2023
Affected
1 pkg
Patched
1 / 1
Exploits
1 known
Exploitation data as of Nov 8, 2023 · OSV.dev, NVD, FIRST.org (EPSS)

Real-World Exposure

1 pkg affected
🦀rocket

Real-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

Affected versions of this crate transmuted a &str to a &'static str before pushing it into a StackVec, this value was then popped later in the same function.

This was assumed to be safe because the reference would be valid while the method's stack was active. In between the push and the pop, however, a function f was called that could invoke a user provided function.

If the user provided panicked, then the assumption used by the function was no longer true and the transmute to &'static would create an illegal static reference to the string. This could result in a freed string being used during (such as in a Drop implementation) or after (e.g through catch_unwind) the panic unwinding.

This flaw was corrected in commit e325e2f by using a guard object to ensure that the &'static str was dropped inside the function.

Affected Packages

1 total 1 fixed
EcosystemPackageVulnerable rangeFix
🦀crates.iorocketall versions0.4.7
Exploits & PoCs
1

Research use only. For defensive security, authorized penetration testing, and academic research only. Never execute exploit code against systems without explicit written authorization.

Detection & mitigation playbook

Open-source dependency
  1. Detect

    Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for rocket. O3's reachability analysis confirms whether the vulnerable code path is actually invoked in your application, so you act on real exposure instead of every transitive match.

  2. Fix

    Update rocket to 0.4.7 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-vcw4-8ph6-7vw8 is resolved across your whole dependency graph.

  3. 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.

  4. How O3 protects you

    O3 pinpoints whether GHSA-vcw4-8ph6-7vw8 is reachable in your code and exactly where to fix it, then blocks exploitation in production at runtime until the patched version is deployed.

Tailored to GHSA-vcw4-8ph6-7vw8. Runtime protection reduces exposure until a permanent patch is applied and verified — it complements patching, it doesn't replace it.

Frequently Asked Questions

Affected versions of this crate transmuted a &str to a &'static str before pushing it into a StackVec, this value was then popped later in the same function. This was assumed to be safe because the reference would be valid while the method's stack was active. In between the push and the pop, however, a function f was called that could invoke a user provided function. If the user provided panicked, then the assumption used by the function was no longer true and the transmute to &'static would create an illegal static reference to the string. This could result in a freed string being used duri
O3 Security · Impact-Aware SCA

Is GHSA-vcw4-8ph6-7vw8 in your dependencies?

O3 detects GHSA-vcw4-8ph6-7vw8 across crates.io dependencies and uses function-level reachability to confirm whether the vulnerable code path is actually reachable — not just present. No false positives.

GHSA-vcw4-8ph6-7vw8: Use after free in… | O3 Security