GHSA-rhfx-m35p-ff5j: Lru `IterMut` Violates Stacked Borrows By Vulnerability
LOWGHSA-rhfx-m35p-ff5j is a LOW `itermut` violates stacked borrows by vulnerability (CWE-476: NULL Pointer Dereference) affecting Lru libraries in the crates.io ecosystem. The issue involves `itermut` violates stacked borrows by invalidating internal pointer. Remediation is available by upgrading affected packages to version 0.16.3.
GHSA-rhfx-m35p-ff5j at a Glance
How to Fix GHSA-rhfx-m35p-ff5j
To remediate this vulnerability, upgrade all affected Lru dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
Upgrade lru to 0.16.3
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
inspect dependencies for lru
How to Check if You Are Affected
To determine whether your application is affected by GHSA-rhfx-m35p-ff5j, inspect your project dependencies for Lru:
inspect dependencies for lru
Analyze the terminal output to locate any version of Lru in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.16.3), your application is affected.
Note: Verify declared build manifests and deployed runtime container environments.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-476: NULL Pointer Dereference, where the product dereferences a pointer that it expects to be valid but is null. In Lru, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
GHSA-rhfx-m35p-ff5j Affected Lru Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
lru
|
crates.io |
≥ 0.9.0
< 0.16.3
|
0.16.3
|
References
Frequently Asked Questions
What is GHSA-rhfx-m35p-ff5j?
Which Lru versions are affected?
What version fixes GHSA-rhfx-m35p-ff5j?
Is lru affected?
What CWE is associated with GHSA-rhfx-m35p-ff5j?
How can I check crates.io dependencies for GHSA-rhfx-m35p-ff5j?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-rhfx-m35p-ff5j",
"modified" : "2026-01-07T20:38:57Z",
"published" : "2026-01-07T20:38:57Z",
"aliases" : [ ],
"summary" : "`IterMut` violates Stacked Borrows by invalidating internal pointer",
"details" : "Affected versions of this crate contain a soundness issue in the `IterMut` iterator implementation. The `IterMut::next` and `IterMut::next_back` methods temporarily create an exclusive reference to the key when dereferencing the internal node pointer.\n\nThis invalidates the shared pointer held by the internal `HashMap`, violating Stacked Borrows rules.",
"severity" : [ {
"type" : "CVSS_V4",
"score" : "CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N/E:U"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "crates.io",
"name" : "lru"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0.9.0"
}, {
"fixed" : "0.16.3"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/jeromefroe/lru-rs/pull/224"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/jeromefroe/lru-rs"
}, {
"type" : "WEB",
"url" : "https://rustsec.org/advisories/RUSTSEC-2026-0002.html"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-476" ],
"severity" : "LOW",
"github_reviewed" : true,
"github_reviewed_at" : "2026-01-07T20:38:57Z",
"nvd_published_at" : null
}
}