Skip to content

fix(deps): update rust crate lru to 0.18.0 [security] - #54

Open
renovate[bot] wants to merge 1 commit into
masterfrom
renovate/crate-lru-vulnerability
Open

fix(deps): update rust crate lru to 0.18.0 [security]#54
renovate[bot] wants to merge 1 commit into
masterfrom
renovate/crate-lru-vulnerability

Conversation

@renovate

@renovate renovate Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

This PR contains the following updates:

Package Type Update Change
lru dependencies minor 0.16.00.18.0

Potential use-after-free due to lack of panic safety in LruCache::pop()

RUSTSEC-2026-0253

More information

Details

LruCache::pop() in lru was not panic-safe. If the Drop implementation of a stored key panics during pop(), self.detach() is never called, leaving dangling pointers in the internal doubly-linked list.

A subsequent cache operation that triggers eviction can then dereference these dangling pointers:

  • The node is freed from the map, but remains linked in the LRU list due to the skipped detach() call
  • When a new insertion causes eviction, the LRU traversal encounters the dangling pointer
  • This results in a write to already-freed memory during the eviction process
Impact
  • CWE-416 (Use-After-Free): memory corruption when subsequent cache operations access freed node pointers in the linked list
  • CWE-415 (Double Free): potential heap corruption when the same memory is freed multiple times

Both types of undefined behavior can be invoked in safe Rust, but only if unwinding panics are enabled and std::panic::catch_unwind is used with key types that have potentially-panicking Drop implementations.

Fix

Fixed in lru 0.18.2 by detaching the node from the linked list before freeing it and dropping the key (lru-rs#238).

Severity

Unknown

References

This data is provided by OSV and the Rust Advisory Database (CC0 1.0).


Release Notes

jeromefroe/lru-rs (lru)

v0.18.2

Compare Source

  • Fix panic-safety unsoundness in pop method.

v0.18.1

Compare Source

  • Add find_and_promote method.

v0.18.0

Compare Source

  • Fix unconstrained lifetime in get_or_insert_mut_ref.

v0.17.0

Compare Source

  • Upgrade hashbrown to 0.17.0 and update MSRV to 1.85.0.

v0.16.4

Compare Source

  • Add get_or_insert_with_key and variants.

Configuration

📅 Schedule: (in timezone America/Denver)

  • Branch creation
    • At any time (no schedule defined)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate Bot added the security label Aug 11, 2026
@changeset-bot

changeset-bot Bot commented Aug 11, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 53b6771

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@renovate
renovate Bot force-pushed the renovate/crate-lru-vulnerability branch from e9fef51 to 427f2da Compare August 26, 2026 21:37
@renovate
renovate Bot force-pushed the renovate/crate-lru-vulnerability branch from 427f2da to 6049429 Compare September 2, 2026 22:33
@renovate
renovate Bot force-pushed the renovate/crate-lru-vulnerability branch from 6049429 to 53b6771 Compare September 7, 2026 18:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants