CVE-2026-115559

published 10 Nov 2026 · updated 17 Nov 2026

imaplib STARTTLS serves plaintext bytes buffered before the handshake as if they came over TLS

6.3MediumCVSS 6.3EPSS 0%

No exploitation in the wild has been reported. EPSS puts the chance of exploitation in the next 30 days at 0%. Fixed in 3.16.0.

IMAP4.starttls() wraps the socket in TLS but leaves self._readbuf, imaplib's own read-ahead buffer, untouched. Any plaintext bytes that arrived in the same recv() as the tagged OK to STARTTLS are returned by readline() after the handshake, so the client treats them as the first responses on the protected channel. A network attacker who cannot break TLS can append forged lines after the server's OK, let the handshake complete with the real server and a valid certificate, and have the client accept the forged CAPABILITY and the forged tagged completion of the next command. This is the STARTTLS command/response injection class of CVE-2011-0411.

Affected

Vendors, products and packages with version ranges

VendorProductVersionsFixed
Python Software Foundation<3.16.03.16.0

Coverage

News and research mentioning this CVE

Timeline

Every event on this vulnerability

Embed

A live severity badge for an advisory, README or ticket

CVE-2026-115559 severity on Zeptric[![CVE-2026-115559](https://zeptric.io/badge/cve/CVE-2026-115559.svg)](https://zeptric.io/cve/CVE-2026-115559)