Tarfile.extract filter bug in CPython <3.16 uid/gid bypass
CVE-2026-4360 Published on June 30, 2026

Tarfile.extract() doesn't fully respect filter parameter
In the Tarfile.extract() function, the filter parameter is not passed properly when extracting hardlinks. An affected system that extracts content from untrusted tar files could end up writing files with an unexpected uid/gid despite the user passing filter='data' to the extract() function.

Vendor Advisory NVD

Vulnerability Analysis

CVE-2026-4360 is exploitable with network access. This vulnerability is considered to have a low attack complexity. The potential impact of an exploit of this vulnerability is considered to have no impact on confidentiality and integrity and availability.

Attack Vector:
NETWORK
Attack Complexity:
LOW
Privileges Required:
HIGH
User Interaction:
PASSIVE

Weakness Type

Improper Preservation of Permissions

The software does not preserve permissions or incorrectly preserves permissions when copying, restoring, or sharing objects, which can cause them to have less restrictive permissions than intended.


Products Associated with CVE-2026-4360

Want to know whenever a new CVE is published for Cpython? stack.watch will email you.

 

Affected Versions

Python Software Foundation CPython:

Exploit Probability

EPSS
0.26%
Percentile
18.18%

EPSS (Exploit Prediction Scoring System) scores estimate the probability that a vulnerability will be exploited in the wild within the next 30 days. The percentile shows you how this score compares to all other vulnerabilities.