CVE-2020-7666 Arbitrary File Write via Archive Extraction (Zip Slip)
Attackers can write arbitrary files outside the intended directory via malicious cpio archives, impacting applications using the u-root cpio package.
- 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-7666?
CVE-2020-7666 is a high-severity path traversal vulnerability in github.com/u-root/u-root/pkg/cpio, 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/cpio. It is vulnerable to leading, non-leading relative path traversal attacks and symlink based (relative and absolute) path traversal attacks in cpio file extraction.
Weakness: CWE-22
Which versions are affected by CVE-2020-7666?
2 open source packages ship an affected version, including github.com/u-root/u-root/pkg/cpio. It affects 1 product.
| Package | Affected | Fixed in |
|---|---|---|
github.com/u-root/u-root/pkg/cpio Go | All versions to 7.0.0 | None |
github.com/u-root/u-root/pkg/cpio Go | All versions to 7.0.0 | None |
Products include U-Root U-Root.
How do I fix CVE-2020-7666?
Upgrade to a fixed version.
Upgrade, and resolve every user-supplied path against an allowed base folder before opening it. More about Path traversal.
Is CVE-2020-7666 being exploited?
There is no known exploitation of CVE-2020-7666 in the wild and no public exploit code.
Other vulnerabilities in github.com/u-root/u-root/pkg/cpio
Sources
Also known as GHSA-mq35-x99r-54fc, MINI-pgqf-hqmc-v84v, MINI-rffj-46fj-52cq, MINI-vr26-q467-h9vh.