Description
If the value passed to os.path.expandvars() is user-controlled a performance degradation is possible when expanding environment variables.
Affected products
python: python
References9
- github.com/python/cpython/issues/136065 Issue TrackingVendor Advisory
- github.com/python/cpython/commit/2e6150adccaaf5bd95d4c19dfd04a3… Patch
- github.com/python/cpython/commit/5dceb93486176e6b4a6d9754491005… Patch
- github.com/python/cpython/commit/631ba3407e3348ccd56ce5160c4fb2… Patch
- github.com/python/cpython/commit/892747b4cf0f95ba8beb51c0d0658b… Patch
- github.com/python/cpython/commit/9ab89c026aa9611c4b0b67c288b830… Patch
- github.com/python/cpython/commit/c8a5f3435c342964e0a432cc9fb448… Patch
- github.com/python/cpython/commit/f029e8db626ddc6e3a3beea4eff511… Patch
- mail.python.org/archives/list/[email protected]/thre… Third Party Advisory
Metrics
- CVSS 3.1
-
5.5
MEDIUM
Score source: NVD
CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H - CVSS 4.0
-
1.8
LOW
Score source: CNA
CVSS:4.0/AV:L/AC:L/AT:P/PR:H/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X - EPSS — exploit probability
- 0% percentile: 4 · as of 10 November 2026
- CWE
- CWE-400
Could this be exploited in your environment?
A patch closes the known hole. A penetration test shows what an attacker can still reach — with proof.