Medium severity · published Jan 23, 2026
CVE-2026-1299
email BytesGenerator header injection due to unquoted newlines
6.0
CVSS
0.6%
EPSS
No
On KEV
Description
The
email module, specifically the "BytesGenerator" class, didn’t properly quote newlines for email headers when
serializing an email message allowing for header injection when an email
is serialized. This is only applicable if using "LiteralHeader" writing headers that don't respect email folding rules, the new behavior will reject the incorrectly folded headers in "BytesGenerator".
Exploitation
Is it being used?
Exploit prediction (EPSS)0.6% · higher than 47% of CVEs
Exploited in the wildNo evidence yet
CISA KEVNot listed
Ransomware campaign useNot known
Affected products
Which versions
CP
CPython · Python Software Foundation
before 3.10.20; 3.11.0 before 3.11.15; 3.12.0 before 3.12.13; 3.13.0 before 3.13.12; 3.14.0 before 3.14.3; 3.15.0a1 before 3.15.0a6 · source: vendor
References
NVD
https://nvd.nist.gov/vuln/detail/CVE-2026-1299
CVE.org
https://www.cve.org/CVERecord?id=CVE-2026-1299
cve.org
https://cve.org/CVERecord?id=CVE-2024-6923
github.com
https://github.com/python/cpython/commit/052e55e7d44718fe46cbba0ca995cb8fcc359413
github.com
https://github.com/python/cpython/commit/0a925ab591c45d6638f37b5e57796f36fa0e56d8
github.com
https://github.com/python/cpython/commit/7877fe424415bc4a13045e62a90a7277413d8cb9
github.com
https://github.com/python/cpython/commit/842ce19a0c0b58d61591e8f6a708c38db1fb94e4
github.com
https://github.com/python/cpython/commit/8cdf6204f4ae821f32993f8fc6bad0d318f95f36
More from CPython
9.4
CVE-2026-115557
Distrust compromised intermediate certificates in ssl module
9.4
CVE-2025-4517
Arbitrary writes via tarfile realpath overflow
9.2
CVE-2026-19445
Use-after-free of a server-side SSLContext when sni_callback switches contexts
8.8
CVE-2026-3298
Out-of-bounds write in Windows asyncio.ProacterEventLoop.sock_recvfrom_into() when using nbytes
8.7
CVE-2024-8088
Infinite loop when iterating over zip archive entry names from zipfile.Path
