RUSTSEC-2026-0205 `Array::insert` violates exception safety if compare function panics, leading to potential Double-Free

Not scored Published

A Rust library's Array::insert method causes a double-free if the user-provided comparison function panics, potentially allowing code execution or crashes.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Not stated
Victim action needed
Not needed
Fix
Available

What is RUSTSEC-2026-0205?

RUSTSEC-2026-0205 is an use after free vulnerability in scc, published on 6 Jul 2026.

Official description

In affected versions of this crate, Array::insert is not exception safe. In the UPSERT path, key and value's snapshot is written to self.data_block, and after the insertion is completed, key and value are mem::forget in order to prevent double free. However, during the insertion, K::compare is invoked, which is a user-provided method. If user deliberately call panic in this function, during unwinding, the destructors of key, value, and self will all be called (since the mem::forget has not been called yet), leading to Double Free. Similar issues happens in the !UPSERT path.

The soundness issue was fixed in version 3.8.4 by using ManuallyDrop instead of mem::forget, and separating fallible code from infallible code during a node split - insert = insert_try -> insert_unchecked.

Which versions are affected by RUSTSEC-2026-0205?

1 open source package ship an affected version, including scc.

PackageAffectedFixed in
scc crates.ioFrom 0.0.0-03.8.4

How do I fix RUSTSEC-2026-0205?

Upgrade scc to 3.8.4 or later.

Upgrade to the fixed version. These bugs are found with fuzzing and sanitisers and avoided by memory-safe languages. More about Use after free.

Is RUSTSEC-2026-0205 being exploited?

There is no known exploitation of RUSTSEC-2026-0205 in the wild and no public exploit code.

Sources

Is RUSTSEC-2026-0205 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free