CVE-2020-7665 Arbitrary File Write via Archive Extraction (Zip Slip)

High 7.5 Published Updated

Attackers can write arbitrary files outside the intended directory via malicious zip archives in the u-root Go library.

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

What is CVE-2020-7665?

CVE-2020-7665 is a high-severity path traversal vulnerability in github.com/u-root/u-root/pkg/uzip, published on 1 Sep 2020. An attacker can exploit it over the internet without logging in, with no action from the victim.

Official description

This affects all versions of package github.com/u-root/u-root/pkg/uzip. It is vulnerable to both leading and non-leading relative path traversal attacks in zip file extraction.

Weakness: CWE-22

Which versions are affected by CVE-2020-7665?

3 open source packages ship an affected version, including github.com/u-root/u-root. It affects 1 product.

PackageAffectedFixed in
github.com/u-root/u-root GoAll versions0.9.0
github.com/u-root/u-root GoAll versions0.9.0
github.com/u-root/u-root GoAll versions0.9.0

Products include U-Root U-Root.

How do I fix CVE-2020-7665?

Upgrade github.com/u-root/u-root to 0.9.0 or later.

Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.

Is CVE-2020-7665 being exploited?

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

Sources

Also known as GHSA-58pf-pcwv-qg85, GO-2022-0793.

Is CVE-2020-7665 in your software?

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

Check your SBOMs for free