Skip to content
Noroxi
CVE-2025-4138· NVD / CVE Program· CNA PSF

Bypassing extraction filter to create symlinks to arbitrary targets outside extraction directory

Allows the extraction filter to be ignored, allowing symlink targets to point outside the destination directory, and the modification of some file metadata. You are affected by this vulnerability if using the tarfile module to extract untrusted tar archives using TarFile.extractall() or TarFile.extract() using the filter= parameter with a value of "data" or "tar". See the tarfile extraction filters documentation https://docs.python.org/3/library/tarfile.html#tarfile-extraction-filter  for more information. Note that for Python 3.14 or later the default value of filter= changed from "no filtering" to `"data", so if you are relying on this new default behavior then your usage is also affected. Note that none of these vulnerabilities significantly affect the installation of source distributions which are tar archives as source distributions already allow arbitrary code execution during the build process. However when evaluating source distributions it's important to avoid installing source distributions with suspicious links.

HighCVSS 7.5 · v3.1—Proof of concept Fix available
Published
Jun 3, 2025
Updated
Jul 31, 2026
EPSS
1.4% · 71th percentile
Follow this CVE

Sign in to follow · You’ll be notified if a followed record enters KEV, gets an exploit or is updated.

Report tools

JSON

Action score

30

Monitor

Low priority for now.

CVSS
30 / 40 · 7.5 / 10
CISA KEV
0 / 30 · Not listed
EPSS
0 / 30 · 1.4%

CISA SSVC decision

Exploitation
none
Automatable
yes
Technical impact
partial

Vulnrichment: CISA's decision-tree inputs.

CNA vs NVD score

NVD
—
CNA · PSF
7.5
NVD has not scored this yet; the score shown is the CNA’s.

The score given by the assigning authority versus NVD’s independent score. A gap means the severity is contested.

Affected systems

—

Versions reported by the vendor

Affected version ranges reported by the assigning authority (PSF). Independent of NVD's CPE analysis and usually ahead of it.

  • Python Software Foundation CPython

    • before 3.9.23affected · python
    • 3.10.0 and later · before 3.10.18affected · python
    • 3.11.0 and later · before 3.11.13affected · python
    • 3.12.0 and later · before 3.12.11affected · python
    • 3.13.0 and later · before 3.13.4affected · python
    • 3.14.0a1 and later · before 3.14.0b3affected · python

Package-level exposure

OSV and GitHub Advisory data: ecosystem, package and range. SBOM matching uses this table.

EcosystemPackageAffected rangeFix
AlmaLinux:10python-unversioned-commandbefore 3.12.9-2.el10_0.23.12.9-2.el10_0.2
AlmaLinux:8platform-pythonbefore 3.6.8-70.el8_10.alma.13.6.8-70.el8_10.alma.1
AlmaLinux:8platform-python-debugbefore 3.6.8-70.el8_10.alma.13.6.8-70.el8_10.alma.1
AlmaLinux:8platform-python-develbefore 3.6.8-70.el8_10.alma.13.6.8-70.el8_10.alma.1
AlmaLinux:8python3-idlebefore 3.6.8-70.el8_10.alma.13.6.8-70.el8_10.alma.1
AlmaLinux:8python3-libsbefore 3.6.8-70.el8_10.alma.13.6.8-70.el8_10.alma.1
AlmaLinux:8python3-testbefore 3.6.8-70.el8_10.alma.13.6.8-70.el8_10.alma.1
AlmaLinux:8python3-tkinterbefore 3.6.8-70.el8_10.alma.13.6.8-70.el8_10.alma.1
AlmaLinux:8python3.11before 3.11.13-1.el8_103.11.13-1.el8_10
AlmaLinux:8python3.11-debugbefore 3.11.13-1.el8_103.11.13-1.el8_10
AlmaLinux:8python3.11-develbefore 3.11.13-1.el8_103.11.13-1.el8_10
AlmaLinux:8python3.11-idlebefore 3.11.13-1.el8_103.11.13-1.el8_10
AlmaLinux:8python3.11-libsbefore 3.11.13-1.el8_103.11.13-1.el8_10
AlmaLinux:8python3.11-rpm-macrosbefore 3.11.13-1.el8_103.11.13-1.el8_10
AlmaLinux:8python3.11-testbefore 3.11.13-1.el8_103.11.13-1.el8_10
AlmaLinux:8python3.11-tkinterbefore 3.11.13-1.el8_103.11.13-1.el8_10
AlmaLinux:8python3.12before 3.12.11-1.el8_103.12.11-1.el8_10
AlmaLinux:8python3.12-debugbefore 3.12.11-1.el8_103.12.11-1.el8_10
AlmaLinux:8python3.12-develbefore 3.12.11-1.el8_103.12.11-1.el8_10
AlmaLinux:8python3.12-idlebefore 3.12.11-1.el8_103.12.11-1.el8_10
AlmaLinux:8python3.12-libsbefore 3.12.11-1.el8_103.12.11-1.el8_10
AlmaLinux:8python3.12-rpm-macrosbefore 3.12.11-1.el8_103.12.11-1.el8_10
AlmaLinux:8python3.12-testbefore 3.12.11-1.el8_103.12.11-1.el8_10
AlmaLinux:8python3.12-tkinterbefore 3.12.11-1.el8_103.12.11-1.el8_10

+96

Other highest-scoring records for the same primary product.

  • CVE-2025-4517Arbitrary writes via tarfile realpath overflow
    37Monitor
  • CVE-2026-19445Use-after-free of a server-side SSLContext when sni_callback switches contexts
    36Monitor
  • CVE-2026-6100Use-after-free in lzma.LZMADecompressor, bz2.BZ2Decompressor, and gzip.GzipFile after re-use under memory pressure
    36Monitor
  • CVE-2026-3298Out-of-bounds write in Windows asyncio.ProacterEventLoop.sock_recvfrom_into() when using nbytes
    35Monitor
  • CVE-2024-12254Unbounded memory buffering in SelectorSocketTransport.writelines()
    35Monitor
  • CVE-2024-8088Infinite loop when iterating over zip archive entry names from zipfile.Path
    34Monitor

Remediation

Which version to upgrade to

Fix versions compiled from the vendor, package registries and Microsoft. Verify the vendor's note before upgrading.

Product / packageFixed versionSource
Python Software Foundation CPython3.10.18Vendor (CNA)
Python Software Foundation CPython3.11.13Vendor (CNA)
Python Software Foundation CPython3.12.11Vendor (CNA)
Python Software Foundation CPython3.13.4Vendor (CNA)
Python Software Foundation CPython3.14.0b3Vendor (CNA)
Python Software Foundation CPython3.9.23Vendor (CNA)
almalinux:python3.113.11.13-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.11-debug3.11.13-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.11-devel3.11.13-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.11-idle3.11.13-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.11-libs3.11.13-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.11-rpm-macros3.11.13-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.11-test3.11.13-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.11-tkinter3.11.13-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.123.12.11-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.12-debug3.12.11-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.12-devel3.12.11-1.el8_10 · AlmaLinux:8Package registry (OSV)
almalinux:python3.12-idle3.12.11-1.el8_10 · AlmaLinux:8Package registry (OSV)
alpine:python33.11.13-r0 · Alpine:v3.19Package registry (OSV)
alpine:python3-tkinter3.12.11-r0 · Alpine:v3.23Package registry (OSV)
debian:pypy37.3.20+dfsg-2 · Debian:14Package registry (OSV)
debian:python3.133.13.4-1 · Debian:13Package registry (OSV)
opensuse:python3103.10.18-150400.4.82.1 · openSUSE:Leap 15.6Package registry (OSV)
opensuse:python310-core3.10.18-150400.4.82.1 · openSUSE:Leap 15.6Package registry (OSV)
opensuse:python310-documentation3.10.18-150400.4.82.1 · openSUSE:Leap 15.6Package registry (OSV)
opensuse:python3123.12.11-150600.3.30.1 · openSUSE:Leap 15.6Package registry (OSV)
opensuse:python312-core3.12.11-150600.3.30.1 · openSUSE:Leap 15.6Package registry (OSV)
opensuse:python312-documentation3.12.11-150600.3.30.1 · openSUSE:Leap 15.6Package registry (OSV)
red hat:python3.110:3.11.13-1.el8_10 · Red Hat:enterprise_linux:8::appstreamPackage registry (OSV)
red hat:python3.11-debug0:3.11.13-1.el8_10 · Red Hat:enterprise_linux:8::crbPackage registry (OSV)

+30

Exploit status

Proof of concept available

A public proof of concept or detection signature exists. Exploit knowledge is out there; don't delay patching.

Evidence

  • Proof-of-concept repository on GitHub ×5

Noroxi does not host or link to exploit code. Metasploit module names and Nuclei template ids are shown (names, not code); Exploit-DB entries and PoC repositories are given as counts only.

Public exploit evidence
SourceKindDate
Proof-of-concept repository on GitHubstars:172026-02-15
Proof-of-concept repository on GitHubstars:42026-02-15
Proof-of-concept repository on GitHubstars:12026-02-16
Proof-of-concept repository on GitHubstars:02026-02-16
Proof-of-concept repository on GitHubstars:02026-02-22

Research context

For pentesters and researchers: attack profile, score disagreement, timeline, patch commits, credits, variant and chain candidates, bug bounty scope. All derived from existing data; no exploit code.

Timeline

From publication to today: proof of concept, Metasploit module, CISA KEV and fix record. Dates are as reported by the sources.

  1. Published
  2. First PoC+257 d
  3. TodaySep 30, 2026+484 d
EPSS, last 120 days

FIRST EPSS daily score; only changes of 0.01 or more are recorded (step chart).

Finders, reporters and analysts named in the CNA record. Click a name for that researcher’s other records.

Variant candidates

Same product, same weakness class, within 18 months. If the patch missed the root cause, the sibling bug is here.

  • CVE-2025-45170 days apartArbitrary writes via tarfile realpath overflow
    37Monitor
  • CVE-2026-11940385 days aparttarfile extraction filter bypass allows escaping the destination directory
    31Monitor
  • CVE-2025-43300 days apartExtraction filter bypass for linking outside extraction directory
    30Monitor
  • CVE-2026-7774366 days aparttarfile.data_filter path traversal bypass allows writing outside the extraction directory
    27Monitor
  • CVE-2026-19672442 days aparttarfile extraction filter bypass allows creation of directories outside the destination
    25Monitor
  • CVE-2026-87910465 days aparttarfile hardlink fallback ignores custom extraction filter rejection via None
    22Monitor

Chain candidates

An authentication bypass and a privilege-requiring bug in the same product, published close together: combined they may become an unauthenticated path.

—

Bug bounty scope

No known public program.

Source: bounty-targets-data (public HackerOne, Bugcrowd, Intigriti, YesWeHack listings).

Technical details

Attack conditions

  • Anyone who can reach it over the internet can trigger it.
  • No account or password is required.
  • No user action is required.
  • No special conditions are required; it is repeatable.

If successful

Confidentiality
high · data can be read
Integrity
none
Availability
none
Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality impact
High
Integrity impact
None
Availability impact
None

CVSS vector

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N

nvd-secondary

Root cause

A user-supplied file name is joined with the allowed directory, but the result is never checked to confirm it is still inside that directory.

A representative example of this vulnerability class. Not the vendor's source code; it shows the faulty pattern and its fix.

Vulnerable

ts
const file = path.join(ROOT, req.query.name);res.sendFile(file);

Fixed

ts
const file = path.resolve(ROOT, req.query.name);if (!file.startsWith(ROOT + path.sep)) {  return res.sendStatus(400);}res.sendFile(file);

Noroxi analysis

No Noroxi analysis for this record yet

We don't hand-write analysis for all 385,000+ vulnerabilities; that wouldn't be honest. For notable, high-impact vulnerabilities our team writes the mechanism, detection and remediation steps.

We use this product, ask for help

Change log

  1. Fix✗ → ✓

For records you follow, these changes also arrive as notifications. →

References

All records