Python os.path.expandvars DoS via env var expansion
CVE-2025-6075 Published on October 31, 2025

Quadratic complexity in os.path.expandvars() with user-controlled template
If the value passed to os.path.expandvars() is user-controlled a performance degradation is possible when expanding environment variables.

Vendor Advisory NVD

Weakness Type

What is a Resource Exhaustion Vulnerability?

The software does not properly control the allocation and maintenance of a limited resource, thereby enabling an actor to influence the amount of resources consumed, eventually leading to the exhaustion of available resources.

CVE-2025-6075 has been classified to as a Resource Exhaustion vulnerability or weakness.


Products Associated with CVE-2025-6075

You can be notified by email with stack.watch whenever vulnerabilities like CVE-2025-6075 are published in these products:

 
 
 

Affected Versions

Python Software Foundation CPython:

Exploit Probability

EPSS
0.03%
Percentile
9.12%

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.