Every CVE Search/ Get API key

CVE-2018-21000

Heap overflow or corruption in safe-transmute

9.8 CriticalFix available

An issue was discovered in the safe-transmute crate before 0.10.1 for Rust. A constructor's arguments are in the wrong order, causing heap memory corruption.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
Low
Privileges needed
None
User interaction
None

What an attacker can affect

Confidentiality
High
Integrity
High
Availability
High

Exploit likelihood

1.98%Up 1.5 points since Apr 14, 2021
90%50%10%1%

What each source reports

NVD Score used 9.8

An issue was discovered in the safe-transmute crate before 0.10.1 for Rust. A constructor's arguments are in the wrong order, causing heap memory corruption.

Record
CVE-2018-21000
CVSS 3.0
9.8 CriticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
CVSS 2.0
7.5 HighAV:N/AC:L/Au:N/C:P/I:P/A:P
Weakness
CWE-119
Updated
2026-11-02
CVE List No score

An issue was discovered in the safe-transmute crate before 0.10.1 for Rust. A constructor's arguments are in the wrong order, causing heap memory corruption.

Record
CVE-2018-21000
Updated
2026-11-02
EUVDEUVD-2021-1518 No score

An issue was discovered in the safe-transmute crate before 0.10.1 for Rust. A constructor's arguments are in the wrong order, causing heap memory corruption.

Record
EUVD-2021-1518
Updated
2026-11-03
GitHub AdvisoriesGHSA-2v78-j59h-fmpf 9.8

Heap overflow or corruption in safe-transmute

Affected versions of this crate switched the length and capacity arguments in the Vec::from_raw_parts() constructor, which could lead to memory corruption or data leakage.

Record
GHSA-2v78-j59h-fmpf
CVSS 3.0
9.8 CriticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Weakness
CWE-119
Updated
2026-11-02
OSV 9.8

An issue was discovered in the safe-transmute crate before 0.10.1 for Rust. A constructor's arguments are in the wrong order, causing heap memory corruption.

Record
CVE-2018-21000
CVSS 3.0
9.8 CriticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Updated
2026-11-02
OSVGHSA-2v78-j59h-fmpf 9.8

Heap overflow or corruption in safe-transmute

Affected versions of this crate switched the length and capacity arguments in the Vec::from_raw_parts() constructor, which could lead to memory corruption or data leakage.

Record
GHSA-2v78-j59h-fmpf
CVSS 3.0
9.8 CriticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Weakness
CWE-119
Updated
2026-11-02
OSVRUSTSEC-2018-0013 9.8

Vec-to-vec transmutations could lead to heap overflow/corruption

Affected versions of this crate switched the length and capacity arguments in the Vec::from_raw_parts() constructor, which could lead to memory corruption or data leakage.

The flaw was corrected by using the constructor correctly.

Record
RUSTSEC-2018-0013
CVSS 3.0
9.8 CriticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Updated
2026-11-02
OSVUBUNTU-CVE-2018-21000 9.8

An issue was discovered in the safe-transmute crate before 0.10.1 for Rust. A constructor's arguments are in the wrong order, causing heap memory corruption.

Record
UBUNTU-CVE-2018-21000
CVSS 3.0
9.8 CriticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
safe-transmute
crates.io
0.4.0 up to 0.10.1
0.10.1
rust-safe-transmute
Ubuntu:20.04:LTS
All versions, plus listed versions
0.10.1-2
None known
rust-safe-transmute
Ubuntu:22.04:LTS
All versions, plus listed versions
0.10.1-2
None known
rust-safe-transmute
Ubuntu:24.04:LTS
All versions, plus listed versions
0.11.2-1
None known
rust-safe-transmute
Ubuntu:25.10
All versions, plus listed versions
0.11.3-1
None known
rust-safe-transmute
Ubuntu:26.10
All versions, plus listed versions
0.11.3-1
None known
rust-safe-transmute
Ubuntu:26.04:LTS
All versions, plus listed versions
0.11.3-1
None known

History

History
RecordedChangedSources
aliasesEUVD
first indexedCVE List, GitHub Advisories, NVD, OSV

Dates are when Every CVE recorded each change. Upstream dates may differ.

In short

CVE-2018-21000 is a critical vulnerability (CVSS 9.8) in Safe-transmute Project Safe-transmute, published November 27, 2018. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 1.98%, the 80th percentile. Fixed in safe-transmute 0.10.1.

References

MoveEnter Open