CVE-2025-4516
CVE-2025-4516 — Use-after-free in "unicode_escape" decoder with error handler
There is an issue in CPython when using `bytes.decode("unicode_escape", error="ignore|replace")`. If you are not using the "unicode_escape" encoding or an error handler your usage is not affected. To work-around this issue you may stop using the error= handler and instead wrap the bytes.decode() call in a try-except catching the DecodeError.
Published Updated Sources: cvelistV5, PSF
Triage
Is it exploited, how likely is exploitation, what does it touch, and how severe do the scoring sources call it.
Exploitation
Unreported
no source claims exploitation
EPSS
<1%
chance of exploitation in 30 days
CVSS base
5.9
MEDIUM
CISA SSVC assessment
Three decision points CISA publishes for the CVEs it assesses · SSVC 2.0.3. A stakeholder decision, not a severity score.
Exploitation
None
none · proof-of-concept · active
Automatable
No
can an attacker script all four kill-chain steps
Technical impact
Partial
partial · total control of the vulnerable component
Affected scope
The catalog records vendors and products as separate lists, not pairs, so which product belongs to which vendor is not something this page can say.
Vendors (1)
Products (1)
Every base score collected
Sources score independently and disagree; each row says who scored it and under which version.
| Score | Version | Severity | Expl. | Impact | Source |
|---|---|---|---|---|---|
| 5.9 | CVSS 4.0 | MEDIUM | n/a | n/a | cvelistV5 |
Weakness & attack patterns
- CWE-416
References
12 on the record
- github.com/python/cpython/issues/133767
issue-tracking
- github.com/python/cpython/pull/129648
patch
- mail.python.org/archives/list/[email protected]/thread/L75IPBBTSCYEF56I2M4KIW353BB3AY74/
vendor-advisory
- github.com/python/cpython/commit/69b4387f78f413e8c47572a85b3478c47eba8142
patch
- github.com/python/cpython/commit/9f69a58623bd01349a18ba0c7a9cb1dad6a51e8e
patch
- github.com/python/cpython/commit/4398b788ffc1f954a2c552da285477d42a571292
patch
- github.com/python/cpython/commit/6279eb8c076d89d3739a6edb393e43c7929b429d
patch
- github.com/python/cpython/commit/73b3040f592436385007918887b7e2132aa8431f
patch
Related CVEs
Same product first, then the same weakness or threat actor.
- CVE-2026-115557 Distrust compromised intermediate certificates in ssl moduleCVSS 9.4
- CVE-2025-24085 Apple Multiple Products Use-After-Free VulnerabilityCVSS 10.0 · CISA KEV
- CVE-2021-22893 Ivanti Pulse Connect Secure Use-After-Free VulnerabilityCVSS 10.0 · CISA KEV
- CVE-2014-8439 Adobe Flash Player Dereferenced Pointer VulnerabilityCVSS 10.0 · CISA KEV
- CVE-2014-1776 Microsoft Internet Explorer Memory Corruption VulnerabilityCVSS 10.0 · CISA KEV
- CVE-2014-0496 Adobe Reader and Acrobat Use-After-Free VulnerabilityCVSS 10.0 · CISA KEV
Elsewhere on this site
- Python Software Foundationevery CVE for this vendor
- CWE-416other pages naming this weakness
Not in any source we poll
Listed rather than left blank: an empty field and an unmeasured one look identical on screen, and only one is a reason to look elsewhere.
- No confirmed IOCs, IP addresses, domains, file hashes, or malware artifacts supplied.
- No organization-specific asset inventory, compensating-control status, or patch deployment evidence supplied.
- No exploit packet captures, log samples, or incident case IDs supplied.