CVE-2026-5222
CVE-2026-5222 is a medium-severity vulnerability in Rust-lang Cargo with a CVSS 3.x base score of 6.5. It is not currently listed as actively exploited by CISA, and its EPSS exploit-prediction score is low. The underlying weakness is classified as CWE-647.
Key facts
- Severity: Medium (CVSS 3.x base score 6.5)
- CVSS v4: 2.3
- EPSS exploit prediction: 0% (25th percentile)
- Actively exploited: Not listed in CISA KEV
- EU (EUVD) id: EUVD-2026-31654
- Weakness: CWE-647
- Affected product: Rust-lang Cargo
- Published:
- Last modified:
Description
Cargo between 1.68 and 1.96 incorrectly normalized the URLs of third-party registries using the sparse index protocol. If a hosting provider allowed multiple registries to be hosted with arbitrary names within the same domain, an attacker able to publish crates in a registry could obtain the credentials of others users of the same registry. The severity of the vulnerability is **low**, due to the extremely niche requirements needed to achieve the attack.
Frequently asked questions
- What is CVE-2026-5222?
- Cargo between 1.68 and 1.96 incorrectly normalized the URLs of third-party registries using the sparse index protocol. If a hosting provider allowed multiple registries to be hosted with arbitrary names within the same domain, an attacker able to publish crates in a registry could obtain the credentials of others users of the same registry. The severity of the vulnerability is **low**, due to the extremely niche requirements needed to achieve the attack.
- How severe is CVE-2026-5222?
- CVE-2026-5222 has a CVSS 3.x base score of 6.5, rated medium severity. It is exploitable over network with low attack complexity, requires low privileges and no user interaction. Impact on confidentiality is high, integrity none, and availability none.
- Is CVE-2026-5222 being actively exploited?
- It is not currently listed in CISA's KEV catalog. Its EPSS exploit-prediction score is 0% (25th percentile), an estimate of the probability of exploitation in the next 30 days.
- What products are affected by CVE-2026-5222?
- CVE-2026-5222 affects Rust-lang Cargo. See the affected-products list for the exact vulnerable versions.
- How do I fix CVE-2026-5222?
- Review the linked vendor and NVD advisories for patched versions and mitigations, then upgrade or apply the recommended workaround.
- Does CVE-2026-5222 have an EU (EUVD) identifier?
- Yes. CVE-2026-5222 is tracked in the ENISA EU Vulnerability Database (EUVD) as EUVD-2026-31654.
- When was CVE-2026-5222 published?
- CVE-2026-5222 was published on 2026-05-25 and last updated on 2026-06-17.
References
- https://blog.rust-lang.org/2026/05/25/cve-2026-5222/
- https://github.com/rust-lang/cargo/pull/17031
- https://groups.google.com/g/rustlang-security-announcements/c/SfUxOiIdY5s
Affected products (1)
- cpe:2.3:a:rust-lang:cargo:*:*:*:*:*:rust:*:*
More vulnerabilities in Rust-lang Cargo
- CVE-2023-38497 — High (CVSS 7.9): Cargo downloads the Rust project’s dependencies and compiles the project. Cargo prior to version 0.72.2, bundled with…
- CVE-2026-5223 — Medium (CVSS 5.3): Cargo incorrectly handled symlinks inside of crate tarballs downloaded from third-party registries, allowing a…
- CVE-2022-46176 — Medium (CVSS 5.3): Cargo is a Rust package manager. The Rust Security Response WG was notified that Cargo did not perform SSH host key…
- CVE-2022-36114 — Medium (CVSS 4.8): Cargo is a package manager for the rust programming language. It was discovered that Cargo did not limit the amount of…
- CVE-2022-36113 — Medium (CVSS 4.6): Cargo is a package manager for the rust programming language. After a package is downloaded, Cargo extracts its source…
All CVEs affecting Rust-lang Cargo →
Other CWE-647 vulnerabilities
- CVE-2022-43939 — High (CVSS 8.6): Hitachi Vantara Pentaho Business Analytics Server versions before 9.4.0.1 and 9.3.0.2, including 8.3.x contain security…
- CVE-2025-64500 — High (CVSS 7.3): Symfony is a PHP framework for web and console applications and a set of reusable PHP components. Symfony's…
- CVE-2025-9909 — Medium (CVSS 6.7): A flaw was found in the Red Hat Ansible Automation Platform Gateway route creation component. This vulnerability allows…
- CVE-2025-66202 — Medium (CVSS 6.5): Astro is a web framework. Versions 5.15.7 and below have a double URL encoding bypass which allows any unauthenticated…
- CVE-2025-47241 — Medium (CVSS 4.0): In browser-use (aka Browser Use) before 0.1.45, URL parsing of allowed_domains is mishandled because userinfo can be…
- CVE-2025-43916 — Low (CVSS 3.4): Sonos api.sonos.com through 2025-04-21, when the /login/v3/oauth endpoint is used, accepts a redirect_uri containing…