CVE-2007-4559

CRITICAL

Python < 3.6.16 - Path Traversal via Tarfile Extract Functions

Title source: llm
STIX 2.1

Exploitation Summary

EIP tracks 7 public exploits for CVE-2007-4559. PoCs published by advanced-threat-research, depers-rus, jithinodattu.

AI-analyzed exploit summary Creosote is a static analysis tool that scans Python files for potential vulnerabilities related to CVE-2007-4559, specifically focusing on unsafe usage of the tarfile module's extract and extractall methods. It categorizes findings into three confidence levels (Vuln, Probable Vuln, Potential Vuln) based on AST analysis.

Description

Directory traversal vulnerability in the (1) extract and (2) extractall functions in the tarfile module in Python allows user-assisted remote attackers to overwrite arbitrary files via a .. (dot dot) sequence in filenames in a TAR archive, a related issue to CVE-2001-1267.

Exploits (7)

nomisec SCANNER 82 stars
by advanced-threat-research · poc
https://github.com/advanced-threat-research/Creosote

Creosote is a static analysis tool that scans Python files for potential vulnerabilities related to CVE-2007-4559, specifically focusing on unsafe usage of the tarfile module's extract and extractall methods. It categorizes findings into three confidence levels (Vuln, Probable Vuln, Potential Vuln) based on AST analysis.

Classification
Scanner 100%
Attack Type
Other
Complexity
Moderate
Reliability
Theoretical
Target: Python applications using the tarfile module
No auth needed
Prerequisites: Access to the target directory containing Python files
devstral-2 · analyzed Feb 18, 2026 Full analysis →
nomisec WORKING POC 1 stars
by depers-rus · poc
https://github.com/depers-rus/CVE-2007-4559

This repository contains a functional Python PoC for CVE-2007-4559, demonstrating a tar path traversal vulnerability. The script creates a malicious TAR archive with a crafted path to escape the extraction directory and overwrite a file in /tmp.

Classification
Working Poc 95%
Attack Type
Other
Complexity
Trivial
Reliability
Reliable
Target: Python tarfile module (versions prior to fix)
No auth needed
Prerequisites: Python environment · Permission to write to target directory
devstral-2 · analyzed Feb 18, 2026 Full analysis →
nomisec WORKING POC
by jithinodattu · poc
https://github.com/jithinodattu/CVE-2007-4559-lab

This repository contains a functional exploit PoC for CVE-2007-4559, demonstrating a directory traversal vulnerability in Python's `tarfile.extractall()` function. The lab includes a Dockerized environment with a vulnerable API, a fixed API, and an attacker component to craft and upload malicious tarballs.

Classification
Working Poc 100%
Attack Type
Auth Bypass
Complexity
Moderate
Reliability
Reliable
Target: Python tarfile module (versions before 3.12)
No auth needed
Prerequisites: Docker · Python 3.11.3 (vulnerable) or 3.12 (fixed)
devstral-2 · analyzed Apr 18, 2026 Full analysis →
nomisec WORKING POC
by m0d0ri205 · poc
https://github.com/m0d0ri205/wargame-tarpioka

This repository contains a functional exploit PoC for CVE-2007-4559, demonstrating a directory traversal vulnerability via crafted tar archives. The exploit leverages path traversal to access files outside the intended directory, such as the flag file.

Classification
Working Poc 90%
Attack Type
Info Leak
Complexity
Moderate
Reliability
Reliable
Target: Custom web application (BubbleTea)
Auth required
Prerequisites: User authentication · Ability to upload tar files
devstral-2 · analyzed Feb 18, 2026 Full analysis →
nomisec WORKING POC
by luigigubello · poc
https://github.com/luigigubello/trellix-tarslip-patch-bypass

This repository demonstrates a bypass for Trellix's patch for CVE-2007-4559, a path traversal vulnerability in tar file extraction. The PoC uses a symlink to bypass the patch's directory traversal check, allowing arbitrary file write outside the intended extraction directory.

Classification
Working Poc 90%
Attack Type
Other
Complexity
Moderate
Reliability
Reliable
Target: Trellix-patched tar extraction utilities
No auth needed
Prerequisites: Docker environment · Python 3.11.6 · Trellix-patched tar extraction utility
devstral-2 · analyzed Feb 18, 2026 Full analysis →
nomisec WRITEUP
by davidholiday · poc
https://github.com/davidholiday/CVE-2007-4559

This repository provides a detailed technical analysis and demonstration of CVE-2007-4559, a directory traversal vulnerability in Python's tarfile module. It includes instructions for crafting a malicious tar file and a Python script to illustrate why the fix in Python 3.11.4 was necessary.

Classification
Writeup 95%
Attack Type
Other
Complexity
Moderate
Reliability
Reliable
Target: Python tarfile module (versions prior to 3.11.4)
No auth needed
Prerequisites: Python environment · Ability to create and extract tar files
devstral-2 · analyzed Feb 18, 2026 Full analysis →
nomisec WORKING POC
by Ooscaar · poc
https://github.com/Ooscaar/MALW

This repository contains a functional exploit for CVE-2007-4559, targeting Polemarch server via a crafted TAR archive to deploy a cryptominer and rootkit. The exploit leverages directory traversal in Python's tarfile module to overwrite arbitrary files.

Classification
Working Poc 95%
Attack Type
Rce
Complexity
Moderate
Reliability
Reliable
Target: Polemarch server (version not specified)
Auth required
Prerequisites: Access to Polemarch server with admin credentials · Ability to upload a crafted TAR file
devstral-2 · analyzed Feb 18, 2026 Full analysis →

References (12)

Core 12
Core References
Broken Link third-party-advisory
http://secunia.com/advisories/26623
Mailing List, Vendor Advisory mailing-list
http://mail.python.org/pipermail/python-dev/2007-August/074290.html
Third Party Advisory vendor-advisory
https://security.gentoo.org/glsa/202309-06

Scores

CVSS v3 9.8
EPSS 0.8936
EPSS Percentile 99.6%
Attack Vector NETWORK
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

CISA SSVC

Vulnrichment
Exploitation poc
Automatable yes
Technical Impact total

Details

CWE
CWE-22
Status published
Products (1)
python/python < 3.6.16
Published Aug 28, 2007
Tracked Since Feb 18, 2026