CVE-2019-16760: rust-lang rust Configuration
Vulnerability summary
CVE-2019-16760 is a high (CVSS 7.5) Configuration vulnerability in rust-lang rust. EPSS estimates a 1.26% chance of exploitation in the next 30 days, higher than 69.1% of scored vulnerabilities. 1 public exploit is recorded.
Timeline
- 30-09-2019PublishedVulnerability first disclosed.
- 05-08-2024Last modifiedVulnerability information updated.
Description
Cargo prior to Rust 1.26.0 may download the wrong dependency if your package.toml file uses the `package` configuration key. Usage of the `package` key to rename dependencies in `Cargo.toml` is ignored in Rust 1.25.0 and prior. When Rust 1.25.0 and prior is used Cargo may download the wrong dependency, which could be squatted on crates.io to be a malicious package. This not only affects manifests that you write locally yourself, but also manifests published to crates.io. Rust 1.0.0 through Rust 1.25.0 is affected by this advisory because Cargo will ignore the `package` key in manifests. Rust 1.26.0 through Rust 1.30.0 are not affected and typically will emit an error because the `package` key is unstable. Rust 1.31.0 and after are not affected because Cargo understands the `package` key. Users of the affected versions are strongly encouraged to update their compiler to the latest available one. Preventing this issue from happening requires updating your compiler to be either Rust 1.26.0 or newer. There will be no point release for Rust versions prior to 1.26.0. Users of Rust 1.19.0 to Rust 1.25.0 can instead apply linked patches to mitigate the issue.
CVSS metrics
6 scores · 5 sources · 2 versions- CVE.orgCNA4.6MediumCVSS:3.1/AV:N/AC:H/PR:L/UI:R/S:U/C:L/I:L/A:LDiffers
- OSV · AlpineEcosystem advisory · calculated7.5HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
- OSV · DebianEcosystem advisory · calculated7.5HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
- OSV · Crates.ioEcosystem advisory · calculated7.5HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:N
EPSS trend
Probability
1.26%
Chance of exploitation in the next 30 days
Percentile
69%
Versus all other CVEs
30-day change
0.00 pp
From 1.26% on 18-09-2026
Known exploited
Compare KEV catalogsNot in any of the 3 tracked catalogs.
Public exploits
1 foundRust
Maturity: poc
Weaknesses
CWE · root cause- CWE-16ConfigurationWeaknesses in this category are typically introduced during the configuration of the software.
- CWE-494Download of Code Without Integrity CheckThe product downloads source code or an executable from a remote location and executes the code without sufficiently verifying the origin and integrity of the code.
Affected systems
Alpine1 product
- rust< 1.26.0-r0
Crates.Io1 product
- cargo< 0.27.0
Debian1 product
- cargo< 0.27.0-1
Rust1 product
- cargo≥ 1.0.0, < 1.26.0
Rust-lang1 product
- rust< 1.26.0
5 vendors · 5 products
References
8 links- github.com/rust-lang/rust/security/advisories/GHSA-phjm-8x66-qw4rX Refsource CONFIRMExploitThird Party AdvisoryWEB
- gist.github.com/pietroalbini/0d293b24a44babbeb6187e06eebd4992X Refsource MISCPatchThird Party AdvisoryWEB