Live threats

All CVEs / Rust-lang

CVE-2026-5222Rust-lang Cargo

Low 2.3 No auth needed

Priority
29
CVSS 4.0
2.3
EPSS
—
Auth required
No
Published
May 25, 2026
Updated
Jul 23, 2026
Category
Application · Cross-platform
Weakness (CWE)
CWE-647
SSVC (CISA)
Exploitation: none · Automatable: no · Technical impact: partial
Vector
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:P/VC:L/VI:N/VA:N/SC:L/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X

What happens

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.

Original NVD text.

What to do

  1. Apply the vendor's security update for Cargo.
  2. It can be exploited without authentication: if you cannot patch now, restrict Internet access to the affected service.

Affected packages

EcosystemPackageAffected versionsFixed inHow to upgrade
crates.io cargo < 0.97.0 0.97.0 cargo update -p cargo --precise 0.97.0

Per OSV / GitHub Advisories (GHSA-p688-r7jv-fm6f). Check the version in your lockfile before upgrading.

Affected products (CPE)

VendorProductVersions
rust-langcargo≥ 1.68.0 < 1.96.0

Official sources

References

Links published by the sources. Open them with care.