cve.bz

CVE-2026-5223 rust-lang cargo: UNIX Symbolic Link (Symlink) Following

6.5 mediumEPSS 0.3%Fix available

Medium (6.5) in rust-lang cargo. EPSS 0.3% estimated probability of exploitation activity in the next 30 days. Fixed in cargo 0.97.0.

On this page
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.

Severity

CVSS 4.0

6.5 medium
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

CVSS 3.1

5.3 medium
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N
EPSS
0.3% (unchanged from 0.3% a week ago; 0.3% 30 days ago) estimated probability of exploitation activity in the next 30 days; 22nd percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: none · Automatable: no · Technical impact: partial, assessed 2026-05-26. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWE
CWE-61 UNIX Symbolic Link (Symlink) Following
OWASP Top 10
A01:2025 Broken Access Control
Published
Modified
NVD analysis
Analyzed
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2026-5223 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2026-5223?via=ask-ai-copy and https://cve.bz/cve/CVE-2026-5223?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2026-5223 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the CNA's record in the CVE List.

ProductAffected
Rust Project Cargofrom 1.0.0 before 1.96.0

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
GHSA-jq42-7mfv-hm57crates.iocargo<0.97.00.97.0

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian12cargo, rustc, rust-cargono fix listedDEBIAN-CVE-2026-5223
Debian13rust-cargono fix listedDEBIAN-CVE-2026-5223
Debian13rustc1.85.1+dfsg1-1+deb13u1DEBIAN-CVE-2026-5223
Debian14rust-cargo0.91.0-3DEBIAN-CVE-2026-5223
Debian14rustc1.95.0+dfsg1-2DEBIAN-CVE-2026-5223
Ubuntu22.04:LTSrustc, rustc-1.62, rustc-1.76 and 11 moreno fix listedUBUNTU-CVE-2026-5223
Ubuntu24.04:LTSrustc, rustc-1.74, rustc-1.76 and 11 moreno fix listedUBUNTU-CVE-2026-5223
Ubuntu25.10rustc-1.85, rustc-1.88, rustc-1.91no fix listedUBUNTU-CVE-2026-5223
Ubuntu26.04:LTSrustc-1.91, rustc-1.92, rustc-1.93no fix listedUBUNTU-CVE-2026-5223
UbuntuPro:14.04:LTSrustcno fix listedUBUNTU-CVE-2026-5223
UbuntuPro:16.04:LTS, Pro:18.04:LTScargo, rustcno fix listedUBUNTU-CVE-2026-5223
UbuntuPro:20.04:LTScargo, rustc, rustc-1.76 and 4 moreno fix listedUBUNTU-CVE-2026-5223
UbuntuPro:22.04:LTScargono fix listedUBUNTU-CVE-2026-5223
Red Hathummingbird:1rust, cargo, clippy and 16 more0:1.97.1-1.1.hum1RHSA-2026:42923
Alpinev3.23rust1.91.1-r2ALPINE-CVE-2026-5223
Alpinev3.24rust, chromium-rust1.96.0-r0ALPINE-CVE-2026-5223
Azure Linux3rust1.75.0-30AZL-88272
Azure Linux3rust1.90.0-9AZL-88278
Alpaquita23rust1.64.0-r4BELL-CVE-2026-5223
Alpaquita25rust1.87.0-r3BELL-CVE-2026-5223
Alpaquitastreamrust1.96.0-r0BELL-CVE-2026-5223

From the distributions' data via OSV.dev: the Debian Security Tracker; Ubuntu Security Notices © Canonical Ltd., CC BY-SA 4.0; Red Hat Security Data © Red Hat, Inc., CC BY 4.0; the Alpine secdb, CC BY-SA 4.0; Microsoft's Azure Linux vulnerability data, MIT; BellSoft's OSV database, MIT. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu · Red Hat · Alpine · Alpaquita.

Red Hat

Red Hat rates this Moderate.

Red Hat's statement

This Moderate vulnerability in Cargo arises from improper handling of symlinks within crate tarballs downloaded from third-party registries. An attacker could exploit this by publishing a malicious crate containing symlinks, leading to the overwrite of source code from other crates in the same registry. Red Hat customers using `crates.io` are not affected, as `crates.io` prohibits symlinks in uploaded crates.

Red Hat's mitigation

To mitigate this issue, avoid using untrusted third-party Cargo registries. If third-party registries are necessary, ensure they enforce strict policies against symlinks in crate tarballs and verify the integrity of downloaded crates. No direct configuration or operational workaround is available within Cargo itself to prevent this specific symlink mishandling when using vulnerable third-party registries.

ProductPackageStateAdvisory
Red Hat Hardened Imagesrust-main-1.97.1-1.1.hum1Fixed 2026-07-21RHSA-2026:42923
Red Hat Enterprise Linux 9gooseFix deferred
Red Hat Enterprise Linux 9greenboot-rsFix deferred
Red Hat Enterprise Linux 9rustFix deferred

Contains Red Hat Security Data © Red Hat, Inc., licensed under CC BY 4.0. Source: https://access.redhat.com/security/data. Modified: reformatted. Red Hat's page for CVE-2026-5223.

Attack patterns (CAPEC)

  • CAPEC-27 Leveraging Race Conditions via Symbolic Links Likelihood: Medium · Severity: High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.

References

Check your stackJSON