CVE-2026-29509
MEDIUMPatool < 4.0.5 Path Traversal via safe_extract() Function
Title source: cnaDescription
Patool before 4.0.5 contains a path traversal vulnerability in the safe_extract() function in patoolib/programs/py_tarfile.py when running on Python before 3.12, where the is_within_directory() helper uses os.path.commonprefix() for character-level string comparison instead of path-level comparison, allowing a crafted archive member path to bypass the containment check. Attackers can supply a malicious archive with specially crafted member paths to write arbitrary files.
References (3)
Core 3
Core References
Release Notes release-notes
https://github.com/wummel/patool/blob/main/doc/changelog.txt
Third Party Advisory third-party-advisory
https://www.vulncheck.com/advisories/patool-path-traversal-via-safe-extract-function
Scores
CVSS v3
5.4
EPSS
0.0028
EPSS Percentile
20.4%
Attack Vector
NETWORK
CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:L/I:L/A:N
CISA SSVC
Vulnrichment
Exploitation
none
Automatable
no
Technical Impact
partial
Details
CWE
CWE-22
Status
published
Products (1)
wummel/patool
< 4.0.5
Published
Jun 26, 2026
Tracked Since
Jun 27, 2026