CVE-2026-115559
published medium CVSS 4.0 · 6.3imaplib STARTTLS serves plaintext bytes buffered before the handshake as if they came over TLS
Package status and fixes
| Distro / vendor | Release | Package / product | Publisher status | Fixed build | Source |
|---|---|---|---|---|---|
| Python Software Foundation | — | CPython0 to < 3.16.0 · Other versions: unaffected | Affected | Not stated | PSF |
| Amazon Linux | AL2 | Release evaluation | Not Affected | Not required | Amazon Linux assessment |
| Amazon Linux | AL2023 | Release evaluation | Not Affected; Pending Fix | Not stated | Amazon Linux assessment |
Description
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.
Related advisories
Vendor advisories explicitly linked to this CVE.
No linked advisories were found for this CVE.
Assessment
CVSS risk assessment and additional context for this vulnerability.
- CVSS version
- 4.0
- Base score
- 6.3 / 10
- Severity
- medium
- Provider
- PSF · cna
- Vector string
- CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N
- Scenarios
- en: GENERAL
Publisher product statements
Version ranges and default statuses as reported by each provider.
| Vendor | Product | Version status | Source |
|---|---|---|---|
| Python Software Foundation | CPython | 0 to < 3.16.0 (affected · python)Default: unaffected | PSF · cna |
Weaknesses
1- CWE-319 CWE-319 Cleartext Transmission of Sensitive Information
References
3Provider assertions
2PSF · cna
imaplib STARTTLS serves plaintext bytes buffered before the handshake as if they came over TLS
CISA-ADP · adp
CISA ADP Vulnrichment
Provenance
- Schema
- 5.2
- Searchable
- yes
- Content hash
- 1efb9835756aa7dd729e65f13d613a760fc2b8c3785eb4e8e1a695b20776c967
- Ingested
- 16 Nov 2026, 18:34:10 UTC
- Source record
- Official CVE record