Path Traversal in Squashfs-Tools Project
CVE-2021-40153
squashfs_opendir in unsquash-1.c in Squashfs-Tools 4.5 stores the filename in the directory entry; this is then used by unsquashfs to create the new file during the unsquash. The filename is not validated for traversal outside of the destination directory, and thus allows writing to locations outside of the destination.
Vulnerability class: Path Traversal (Directory Traversal)
Published · last modified .
CVSS v3 metric
CVSS v3 base score 8.1 (High). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:N/I:H/A:H.
EPSS exploit prediction
EPSS 0.025, 85.0th percentile (last changed ); unchanged over 30 days. About EPSS.
Affected products
- Squashfs-Tools Project — versions 4.5
- Debian Linux — versions 9.0, 10.0
- Fedoraproject Fedora — versions 34, 33
- Red Hat Enterprise Linux — versions 7.0, 8.0
Weakness classification (CWE)
Public exploits and proof-of-concept code
Also mentioned in 2 other repositories (ARPSyndicate/cvemon, n0-traces/cve_monitor). These reference the CVE in a list, notes or a scanner and are not exploit code for it.
References
- github.com/plougher/squashfs-tools/commit/79b5a555058eef4e1e7ff220c344d39f8cd09… (Patch, Third Party Advisory)
- github.com/plougher/squashfs-tools/issues/72 (Exploit, Third Party Advisory)
- bugs.launchpad.net/ubuntu/+source/squashfs-tools/+bug/1941790 (Third Party Advisory)
- FEDORA-2021-cdbd827c1e (vendor-advisory)
- [debian-lts-announce] 20210831 [SECURITY] [DLA 2752-1] squashfs-tools security update (mailing-list, Mailing List, Third Party Advisory)
- DSA-4967 (vendor-advisory, Third Party Advisory)
- FEDORA-2021-9fb6da134f (vendor-advisory)
- GLSA-202305-29 (vendor-advisory)