oss-sec mailing list archives
CPython CVE-2025-4516: Use-after-free crash using bytes.decode("unicode_escape", error="ignore|replace")
From: Alan Coopersmith <alan.coopersmith () oracle com>
Date: Fri, 16 May 2025 09:10:17 -0700
-------- Forwarded Message --------Subject: [Security-announce][CVE-2025-4516] Use-after-free crash using bytes.decode("unicode_escape", error="ignore|replace")
Date: Thu, 15 May 2025 09:33:30 -0400 From: Seth Larson <seth () python org> Reply-To: security-sig () python org To: security-announce () python orgThere is a MEDIUM severity security issue in CPython when using `bytes.decode("unicode_escape", error="ignore|replace")`. The use-after-free being exploited would likely result in a crash.
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 decoding error.
Please see the linked CVE ID for the latest information on affected versions: * https://www.cve.org/CVERecord?id=CVE-2025-4516 * https://github.com/python/cpython/pull/129648 _______________________________________________ Security-announce mailing list -- security-announce () python org https://mail.python.org/mailman3/lists/security-announce.python.org/
Current thread:
- CPython CVE-2025-4516: Use-after-free crash using bytes.decode("unicode_escape", error="ignore|replace") Alan Coopersmith (May 16)
