GHSA-2wq5-g96f-mv3v Segmentation fault due to use of uninitialized memory

Not scored Published

An attacker can cause a segmentation fault and denial of service by providing a crafted zip file to the ouch library.

Exploited in the wild
Not known
Login needed
Not needed
Attackable
Local or same network only
Victim action needed
A user has to click or open something
Fix
Available

What is GHSA-2wq5-g96f-mv3v?

GHSA-2wq5-g96f-mv3v is a memory corruption vulnerability in ouch, published on 22 Sep 2024. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.

Official description

When trying to decompress a file using "ouch", we can reach the function "ouch::archive::zip::convert_zip_date_time". In the function, there is a unsafe function, "transmute". Once the "transmute" function is called to convert the type of "month" object, the address of the object is changed to the uninitialized memory region. After that, when other function tries to dereference "month", segmentation fault occurs.

Which versions are affected by GHSA-2wq5-g96f-mv3v?

3 open source packages ship an affected version, including ouch.

PackageAffectedFixed in
ouch crates.ioAll versions0.3.1
ouch crates.ioAll versions0.3.1
ouch crates.ioFrom 0.0.0-00.3.2-0

How do I fix GHSA-2wq5-g96f-mv3v?

Upgrade ouch to a fixed version for your release line: 0.3.1 or 0.3.2-0.

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

Is GHSA-2wq5-g96f-mv3v being exploited?

There is no known exploitation of GHSA-2wq5-g96f-mv3v in the wild and no public exploit code.

Sources

Also known as RUSTSEC-2024-0374.

Is GHSA-2wq5-g96f-mv3v in your software?

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

Check your SBOMs for free