CVE-2026-4360: CWE-281 in Python Software Foundation CPython
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.
AI Analysis
Technical Summary
The vulnerability in CPython's Tarfile.extract() function (CVE-2026-4360) involves improper handling of the filter parameter when extracting hardlinks from tar archives. Specifically, the filter parameter intended to restrict extraction is not passed properly for hardlinks, potentially allowing files to be created with unexpected uid/gid values. This could occur when extracting content from untrusted tar files. The issue is tracked under CWE-281 (Improper Restriction of Operations within the Bounds of a Memory Buffer). Affected versions include all CPython versions before 3.16.0, including 3.15.0a1 and 3.14.0. The CVSS 4.0 base score is 2.0, indicating low severity. No official fix or patch has been documented yet.
Potential Impact
An attacker who can supply a crafted tar file to an affected system may cause files to be extracted with unexpected user and group IDs, potentially leading to unauthorized file ownership or access. However, the impact is limited by the low CVSS score and the requirement for user interaction and privileges (high privileges needed to exploit). There are no known active exploits in the wild.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Until an official fix is released, users should avoid extracting tar files from untrusted sources or apply additional manual checks on extracted file ownership. Monitor Python Software Foundation advisories for updates.
CVE-2026-4360: CWE-281 in Python Software Foundation CPython
Description
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.
CVSS v4.0
Score 2.0low
Affected software
Python Software Foundation
CPython
pkg:github/CPythonRun on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability in CPython's Tarfile.extract() function (CVE-2026-4360) involves improper handling of the filter parameter when extracting hardlinks from tar archives. Specifically, the filter parameter intended to restrict extraction is not passed properly for hardlinks, potentially allowing files to be created with unexpected uid/gid values. This could occur when extracting content from untrusted tar files. The issue is tracked under CWE-281 (Improper Restriction of Operations within the Bounds of a Memory Buffer). Affected versions include all CPython versions before 3.16.0, including 3.15.0a1 and 3.14.0. The CVSS 4.0 base score is 2.0, indicating low severity. No official fix or patch has been documented yet.
Potential Impact
An attacker who can supply a crafted tar file to an affected system may cause files to be extracted with unexpected user and group IDs, potentially leading to unauthorized file ownership or access. However, the impact is limited by the low CVSS score and the requirement for user interaction and privileges (high privileges needed to exploit). There are no known active exploits in the wild.
Mitigation Recommendations
Patch status is not yet confirmed — check the vendor advisory for current remediation guidance. Until an official fix is released, users should avoid extracting tar files from untrusted sources or apply additional manual checks on extracted file ownership. Monitor Python Software Foundation advisories for updates.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- PSF
- Date Reserved
- 2026-03-17T19:25:46.527Z
- Cvss Version
- 4.0
- State
- PUBLISHED
Threat ID: 6a43db7c27e9c79719f8cbd4
Added to database: 06/30/2026, 15:06:36 UTC
Last enriched: 08/12/2026, 15:08:02 UTC
Last updated: 09/28/2026, 13:47:45 UTC
Views: 181
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
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
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.