Skip to main content
EPSS 0.6%top 53%

CVE-2026-7774: CWE-22 in Python Software Foundation CPython

0
Medium
Published: 06/08/2026 (06/08/2026, 08:13:38 UTC)
Source: CVE Database V5
Vendor/Project: Python Software Foundation
Product: CPython

Description

tarfile.data_filter could be bypassed using crafted link entries, including symlinks with empty or directory-like names, to redirect later archive members outside the intended extraction directory. This allowed a malicious tar archive to cause tarfile.extractall() to write files outside the destination directory, subject to the permissions of the extracting process.

CVSS v4.0

Score 6.9medium

Attack Vector
Network
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
Active
Vuln. Confidentiality
None
Vuln. Integrity
High
Vuln. Availability
None
Subsq. Confidentiality
None
Subsq. Integrity
None
Subsq. Availability
None
CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:A/VC:N/VI:H/VA:N/SC:N/SI:N/SA:N

Affected software

Python Software Foundation

CPython

Affected versions
>=0 <3.10.21>=3.11.0 <3.11.16>=3.12.0 <3.12.14>=3.13.0 <3.13.14>=3.14.0 <3.14.6>=3.15.0a1 <3.15.0b2
cpython
pkg:pypi/cpython
Affected versions
=3.14.0=3.15.0
GitHub Actionsmore threats →cve
CPython
pkg:github/CPython
Affected versions
>=0 <3.10.21>=3.11.0 <3.11.16>=3.12.0 <3.12.14>=3.13.0 <3.13.14>=3.14.0 <3.14.6>=3.15.0a1 <3.15.0b2

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 08/13/2026, 13:10:55 UTC

Technical Analysis

The vulnerability in Python's CPython tarfile module (CVE-2026-7774) involves a bypass of the data_filter function through specially crafted link entries, including symbolic links with empty or directory-like names. This bypass enables an attacker to redirect extraction of archive members outside the target directory when using tarfile.extractall(). The flaw is a directory traversal issue categorized under CWE-22. It affects multiple CPython versions including 3.11.0, 3.12.0, 3.13.0, 3.14.0, and 3.15.0a1. The CVSS 4.0 base score is 6.9 (medium severity), indicating a network attack vector with low complexity and no privileges required, but requiring user interaction and resulting in high impact on integrity.

Potential Impact

Successful exploitation allows an attacker to write files outside the intended extraction directory, potentially overwriting or creating arbitrary files on the target system with the permissions of the user running the extraction. This can lead to unauthorized file modification or code execution depending on the context and permissions. There are no known exploits in the wild at this time.

Mitigation Recommendations

Patch status is not yet confirmed — check the Python Software Foundation advisory for current remediation guidance. Until a fix is available, avoid extracting untrusted tar archives with tarfile.extractall() or use safer extraction methods that validate paths. Monitor official Python channels for updates and patches.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Data Version
5.2
Assigner Short Name
PSF
Date Reserved
2026-05-04T14:47:51.154Z
Cvss Version
4.0
State
PUBLISHED

Threat ID: 6a219e6ee29bf47b50b44825

Added to database: 06/04/2026, 15:49:02 UTC

Last enriched: 08/13/2026, 13:10:55 UTC

Last updated: 09/14/2026, 22:01:37 UTC

Views: 107

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses