Python tarfile module directory traversal via dot dot sequences
CVE-2007-4559Critical
The extract and extractall functions in Python's tarfile module do not properly validate filenames containing dot dot sequences. An attacker can craft a TAR archive with specially crafted filenames that traverse directories during extraction, allowing them to overwrite arbitrary files on the system. The attacker needs a user to extract a malicious TAR archive using the vulnerable functions.
Plain English summary of the NVD and CISA text, checked by machine against both.
Scores and dates
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Detail
Affected versions
- python python: before 3.6.16
- python python: from 3.7.0, before 3.8.17
- python python: from 3.9.0, before 3.9.17
- python python: from 3.10.0, before 3.10.12
- python python: from 3.11.0, before 3.11.4