RUSTSEC-2026-0001 Potential Undefined Behaviors in `Arc<T>`/`Rc<T>` impls of `from_value` on OOM
Attackers can trigger undefined behavior and potential code execution or crashes by causing out-of-memory conditions during deserialization of shared pointers.
- Exploited in the wild
- Not known
- Login needed
- Not needed
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is RUSTSEC-2026-0001?
RUSTSEC-2026-0001 is a vulnerability in rkyv, published on 5 Jan 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.
Official description
The SharedPointer::alloc implementation for sync::Arc<T> and rc::Rc<T> in rkyv/src/impls/alloc/rc/atomic.rs (and rc.rs) does not check if the allocator returns a null pointer on OOM (Out of Memory).
This null pointer can flow through to SharedPointer::from_value, which calls Box::from_raw(ptr) with the null pointer. This triggers undefined behavior when utilizing safe deserialization APIs (such as rkyv::from_bytes or rkyv::deserialize_using) if an OOM condition occurs during the allocation of the shared pointer.
The issue is reachable through safe code and violates Rust's safety guarantees.
Which versions are affected by RUSTSEC-2026-0001?
1 open source package ship an affected version, including rkyv.
| Package | Affected | Fixed in |
|---|---|---|
rkyv crates.io | From 0.0.0-0 | 0.7.46, 0.8.13 |
How do I fix RUSTSEC-2026-0001?
Upgrade rkyv to a fixed version for your release line: 0.7.46 or 0.8.13.
Is RUSTSEC-2026-0001 being exploited?
There is no known exploitation of RUSTSEC-2026-0001 in the wild and no public exploit code.