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 involves improper handling of the filter parameter during extraction of hardlinks. Specifically, when extracting content from untrusted tar files, the filter parameter intended to restrict extraction behavior is not passed properly for hardlinks. This can result in files being created with unexpected uid/gid values, potentially violating user intent and security policies. The issue is tracked as CWE-281 (Improper Restriction of Operations within the Bounds of a Memory Buffer).
Potential Impact
An attacker who can supply a crafted tar file to a system extracting tar archives using the vulnerable Tarfile.extract() function may cause files to be written with unexpected user and group IDs. This could lead to unauthorized file ownership or access control issues. However, the CVSS score is low (2.0), indicating limited impact and requiring privileges to exploit (PR:H). No known exploits are reported in the wild.
Mitigation Recommendations
Patch status is not yet confirmed — check the Python Software Foundation advisory for current remediation guidance. Until a fix is available, users should avoid extracting untrusted tar files with the Tarfile.extract() function or apply additional manual checks on extracted file ownership. Monitor official Python channels for updates and patches addressing this issue.
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
Run 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 involves improper handling of the filter parameter during extraction of hardlinks. Specifically, when extracting content from untrusted tar files, the filter parameter intended to restrict extraction behavior is not passed properly for hardlinks. This can result in files being created with unexpected uid/gid values, potentially violating user intent and security policies. The issue is tracked as CWE-281 (Improper Restriction of Operations within the Bounds of a Memory Buffer).
Potential Impact
An attacker who can supply a crafted tar file to a system extracting tar archives using the vulnerable Tarfile.extract() function may cause files to be written with unexpected user and group IDs. This could lead to unauthorized file ownership or access control issues. However, the CVSS score is low (2.0), indicating limited impact and requiring privileges to exploit (PR:H). No known exploits are reported in the wild.
Mitigation Recommendations
Patch status is not yet confirmed — check the Python Software Foundation advisory for current remediation guidance. Until a fix is available, users should avoid extracting untrusted tar files with the Tarfile.extract() function or apply additional manual checks on extracted file ownership. Monitor official Python channels for updates and patches addressing this issue.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- PSF
- Date Reserved
- 2026-03-17T19:25:46.527Z
- Cvss Version
- 4.0
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a43db7c27e9c79719f8cbd4
Added to database: 06/30/2026, 15:06:36 UTC
Last enriched: 08/05/2026, 13:13:32 UTC
Last updated: 08/12/2026, 00:41:13 UTC
Views: 125
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.