CVE-2020-36317: rust-lang rust Out-of-bounds Write
Vulnerability summary
CVE-2020-36317 is a high (CVSS 7.5) Out-of-bounds Write vulnerability in rust-lang rust. EPSS estimates a 1.50% chance of exploitation in the next 30 days, higher than 73.8% of scored vulnerabilities. 1 public exploit is recorded.
Advisory lineage
Upstream 0 · Downstream 2Timeline
- 11-04-2021PublishedVulnerability first disclosed.
- 04-08-2024Last modifiedVulnerability information updated.
Description
In the standard library in Rust before 1.49.0, String::retain() function has a panic safety problem. It allows creation of a non-UTF-8 Rust string when the provided closure panics. This bug could result in a memory safety violation when other string APIs assume that UTF-8 encoding is used on the same string.
CVSS metrics
4 scores · 3 sources · 2 versions- OSV · UbuntuEcosystem advisory · calculated7.5HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
- OSV · DebianEcosystem advisory · calculated7.5HighCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H
EPSS trend
Probability
1.50%
Chance of exploitation in the next 30 days
Percentile
74%
Versus all other CVEs
30-day change
0.00 pp
From 1.50% on 19-09-2026
Known exploited
Compare KEV catalogsNot in any of the 3 tracked catalogs.
Public exploits
1 foundRust
Maturity: poc
Weaknesses
CWE · root causeAffected systems
Debian1 product
- rustc< 1.53.0+dfsg1-1
Rust-lang1 product
- rust< 1.49.0
Ubuntu1 product
- rustcAll versions (No fix recorded) | < 1.51.0+dfsg1+llvm-1~exp3ubuntu1~20.04.2
3 vendors · 3 products
References
6 links- github.com/rust-lang/rust/issues/78498X Refsource MISCREPORTExploitIssue TrackingThird Party Advisory