shutil.unpack_archive() doesn't check for Windows absolute paths in ZIPs
CVE-2026-3087Published 27 Apr 2026, 20:46 UTC
Real-world risk
1.6/ 10Low
Routine
If the vulnerable configuration applies to you: 3.6
PreliminaryFrom the CVSS vector only · confidence low
CVSS
6.0
scored by the vendor (CNA), CVSS 4.0
In plain words
No plain-language summary yet. The original description is below.
Original description (from PSF)
If `shutil.unpack_archive()` is given a ZIP archive with an absolute Windows path containing a drive (`C:\\...`) then the archive will be extracted outside the target directory which is different than other operating systems. Only Windows is affected by this vulnerability.
Am I affected?
| Product | Affected versions (from the sources) | Fixed in |
|---|---|---|
| CPythonUbiquitous | < 3.10.21; >= 3.11.0, < 3.11.16; >= 3.12.0, < 3.12.14; >= 3.13.0, < 3.13.14; >= 3.14.0a1, < 3.14.5rc1; >= 3.15.0a1, < 3.15.0b1 | 3.10.21, 3.11.16, 3.12.14, 3.13.14, 3.14.5rc1, 3.15.0b1 |
What to do
Update to a fixed version: 3.10.21, 3.11.16, 3.12.14, 3.13.14, 3.14.5rc1, 3.15.0b1.
Why this score
| Factor | Value | Evidence | × |
|---|---|---|---|
| Impact | Major data tamperingWrites or changes important data without gaining execution | From the CVSS vector | 0.70 |
| Attacker position | InternetAnyone on the Internet can reach a typical deployment | From the CVSS vector | 1.00 |
| Privileges needed | LowA real low-privileged account | From the CVSS vector | 0.60 |
| Victim interaction | NoneNothing | From the CVSS vector | 1.00 |
| Configuration | UncommonNeeds a non-default feature that a minority enables | From the CVSS vector | 0.45 |
| Reliability | ReliableDeterministic: injection, logic bug, path traversal | From the CVSS vector | 1.00 |
Threat level T1: Nothing known (× 0.85)
The default for a new disclosure
EPSS 0.5% chance of exploitation in 30 days (percentile 46), as of 2026-12-03.
The arithmetic
- Prerequisites multiplied together0.270
- Threat T1: Nothing known0.850
- 10 × impact 0.7 × prerequisites 0.27 × threat 0.851.607
- Rounded to one decimal between 0.1 and 101.6
Exploitation and evidence timeline
- 27 Apr 2026 Published
- 3 Dec 2026 Risk 1.6 (cvss fallback)
Weakness
CWE-22
References
- https://github.com/python/cpython/pull/146591patch
- https://github.com/python/cpython/issues/146581issue-tracking
- https://mail.python.org/archives/list/[email protected]/thread/X6FXE5C6KDKOVNX3EC3DWD5RUPFWOZA4/vendor-advisory
- https://github.com/python/cpython/commit/ab5ef98af693bded74a738570e81ea70abef2840patch
- https://github.com/python/cpython/commit/b01e594fbe754a960212f908d047294e880b52fdpatch
- https://github.com/python/cpython/commit/fc829e88753858c8ac669594bf0093f44948c0f4patch
- https://github.com/python/cpython/commit/65b255416ae217bf0e22085be3c1976cea18bd8cpatch
- https://github.com/python/cpython/commit/8e13025747e1ca72e86d1f35637123f9c306f0cbpatch
- https://github.com/python/cpython/commit/8ee6aff14054b37b53e47194a2fa313e98163c94patch
- https://github.com/python/cpython/commit/ba0aca3bffce431fe2fbd53ca4cd6a717a2e2c19patch
- https://github.com/python/cpython/commit/a6650a2cdf0c49fb8ce0c982903aa2aa274beefepatch
- https://github.com/python/cpython/commit/7ef7dd0a74f47facd1fadcbc77f8fb03beb5eb4dpatch
- https://github.com/python/cpython/commit/1071290169f85c09cf767c1099564a9426cdc7e8patch
- http://www.openwall.com/lists/oss-security/2026/04/28/9
- CVE-2026-3087 on CVE.org