CVE-2021-28875 Memory corruption in n/a

High 7.5 Published Updated

A buffer overflow in the Rust standard library's read_to_end function allows attackers to execute arbitrary code or cause denial of service.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2021-28875?

CVE-2021-28875 is a high-severity memory corruption vulnerability in n/a, published on 11 Apr 2021. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

In the standard library in Rust before 1.50.0, read_to_end() does not validate the return value from Read in an unsafe context. This bug could lead to a buffer overflow.

Weakness: CWE-252

Which versions are affected by CVE-2021-28875?

It affects 1 product.

Products include Rust-Lang Rust.

How do I fix CVE-2021-28875?

Upgrade to a fixed version.

Upgrade to the fixed version. Memory-safe languages, compiler hardening and fuzzing prevent most new cases. More about Memory corruption.

Is CVE-2021-28875 being exploited?

There is no known exploitation of CVE-2021-28875 in the wild and no public exploit code.

Sources

Also known as DEBIAN-CVE-2021-28875, GHSA-fhrh-9gc2-pfgh, UBUNTU-CVE-2021-28875.

Is CVE-2021-28875 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free