cve.bz

CVE-2020-36318 rust-lang rust: Double Free

9.8 criticalExploit referenceEPSS 1.7%Fix available

Critical (9.8) in rust-lang rust. EPSS 1.7% estimated probability of exploitation activity in the next 30 days.

On this page
In the standard library in Rust before 1.49.0, VecDeque::make_contiguous has a bug that pops the same element more than once under certain condition. This bug could result in a use-after-free or double free.

Severity

CVSS 3.1

9.8 critical
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS
1.7% (unchanged from 1.7% a week ago; 1.7% 30 days ago) estimated probability of exploitation activity in the next 30 days; 77th percentile. Scored 2026-11-21. A forecast for this CVE across the internet, not for your own systems.
CWEs
CWE-415 Double Free
CWE-416 Use After Free
Published
Modified
NVD analysis
Analyzed, since modified
Record from
the NVD, synced

Fix and patched versions

Ask an AI about this CVE

Show the promptExplain CVE-2020-36318 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2020-36318?via=ask-ai-copy and https://cve.bz/cve/CVE-2020-36318?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-2020-36318 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 NVD's CPE matches.

ProductAffected
rust-lang:rustfrom 1.48.0 before 1.49.0

Linux distributions

DistributionReleasePackageFixed inAdvisory
Debian12, 13, 14rustc1.53.0+dfsg1-1DEBIAN-CVE-2020-36318
UbuntuPro:14.04:LTS, Pro:16.04:LTSrustcno fix listedUBUNTU-CVE-2020-36318
Red Hatdevtools:2021rust-toolset-1.49, rust-toolset-1.49-rls, rust-toolset-1.49-rust and 14 more0:1.49.0-1.el7_9RHSA-2021:2243
Red Hatenterprise_linux:8::appstreamrls, rust, cargo and 17 more0:1.49.0-1.module+el8.4.0+9446+1a463e08RHSA-2021:1935
Rocky Linux8rust, rust-toolset0:1.49.0-1.module+el8.4.0+416+259a129aRLSA-2021:1935

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; Rocky Linux's errata, BSD-3-Clause. Modified: reformatted and linked to CVE records. Credits. On the distributions' own pages: Debian · Ubuntu · Red Hat.

Red Hat

Red Hat rates this Moderate.

Red Hat's statement

VecDeque::make_contiguous is not considered stable is versions of rust prior to 1:48. As a result, it should not be used as shipped in Red Hat Enterprise Linux versions 8.3 and older.

ProductPackageStateAdvisory
Red Hat Developer Toolsrust-toolset-1.49-0:1.49.0-1.el7_9Fixed 2021-06-03RHSA-2021:2243
Red Hat Developer Toolsrust-toolset-1.49-rust-0:1.49.0-1.el7_9Fixed 2021-06-03RHSA-2021:2243
Red Hat Enterprise Linux 8rust-toolset:rhel8-8040020210113215649.bd734dcaFixed 2021-05-18RHSA-2021:1935
Red Hat Enterprise Linux 9rustNot affected

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-2020-36318.

References

Check your stackJSON