VAITP Dataset

← Back to the dataset

CVE-2026-115557

Python's ssl module denies compromised certificates via built‑in denylist.

  • CVSS 9.4
  • CWE-299
  • Configuration Issues
  • Remote

Python has added a denylist for known compromised certificates to the "ssl" module to ensure user safety even without certificate revocation configured. Known compromised certificates will automatically be rejected regardless of the SSLContext policy configuration.

CVSS base score
9.4
Published
2026-10-24
OWASP
A02 Cryptographic Failures
Orthogonal defect classification
Checking
Code defect classification
Missing Check
Category
Configuration Issues
Subcategory
Improper SSL/TLS Certificate Validation
Accessibility scope
Remote
Impact
Unauthorized Access
Affected component
Python
Fixed by upgrading
Yes

Solution

Upgrade Python to 3.12.2 or later, which includes the compromised‑certificate denylist in the ssl module.

Vulnerable code sample

import ssl
import socket

def fetch_data(host, port=443):
    # VULNERABLE: disables verification, allowing compromised certificates
    ctx = ssl.SSLContext(ssl.PROTOCOL_TLS_CLIENT)
    ctx.check_hostname = False
    ctx.verify_mode = ssl.CERT_NONE
    sock = socket.create_connection((host, port))
    ssock = ctx.wrap_socket(sock, server_hostname=host)
    ssock.sendall(b"GET / HTTP/1.1\r\nHost: " + host.encode() + b"\r\n\r\n")
    return ssock.recv(4096)

Patched code sample

import ssl
import socket

def fetch_data(host, port=443):
    # FIX: use default context with verification; denylist will reject compromised certs
    ctx = ssl.create_default_context()
    sock = socket.create_connection((host, port))
    ssock = ctx.wrap_socket(sock, server_hostname=host)
    ssock.sendall(b"GET / HTTP/1.1\r\nHost: " + host.encode() + b"\r\n\r\n")
    return ssock.recv(4096)

Cite this entry

@misc{vaitp:cve2026115557,
  title        = {{Python's ssl module denies compromised certificates via built‑in denylist.}},
  author       = {Bogaerts, Fr\'ed\'eric and Ivaki, Naghmeh and Fonseca, Jos\'e},
  year         = {2026},
  note         = {VAITP Python Vulnerability Dataset, entry CVE-2026-115557},
  howpublished = {\url{https://netpack.pt/vaitp/vulnerability/CVE-2026-115557/}}
}

Download this entry as JSON Download the whole dataset

Introducing the "VAITP dataset": a specialized repository of Python vulnerabilities and patches, meticulously compiled for the use of the security research community. As Python's prominence grows, understanding and addressing potential security vulnerabilities become crucial. Crafted by and for the cybersecurity community, this dataset offers a valuable resource for researchers, analysts, and developers to analyze and mitigate the security risks associated with Python. Through the comprehensive exploration of vulnerabilities and corresponding patches, the VAITP dataset fosters a safer and more resilient Python ecosystem, encouraging collaborative advancements in programming security.

The supreme art of war is to subdue the enemy without fighting.

Sun Tzu – “The Art of War”

:: Shaping the future through research and ingenuity ::

Before you use the VAITP AI models

Please read and accept the following disclaimer:

By choosing "I understand and accept", you acknowledge that you understand and agree to these terms.