Skip to main content

HTTPX2 CVE-2026-84378

| EUVDEUVD-2026-70242 MEDIUM
Inefficient Algorithmic Complexity (CWE-407)
2026-09-02 GitHub_M GHSA-f2fp-rgf2-35cp
5.9
CVSS 3.1 · Vendor: GitHub_M
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Recon
    Attacker controls or compromises SSE endpoint
  2. Delivery
    Client application calls .sse() and connects
  3. Exploit
    Endpoint returns valid text/event-stream response
  4. Install
    Single long data line delivered across thousands of micro-chunks
  5. C2
    Each chunk triggers full buffer rescan in _SSELineDecoder
  6. Execute
    Quadratic CPU growth saturates worker thread or event loop
  7. Impact
    Application becomes unresponsive

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V2 - Validation and Business Logic Algorithmic complexity limits
Exploitation Conditions

The target application must be running HTTPX2 version 2.5.0 through 2.9.x and must invoke httpx2.Client.sse() or httpx2.AsyncClient.sse() - the vulnerability exists only on the SSE code path, not on ordinary HTTP requests. The attacker must be able to control the response delivered to the client: either by operating the SSE endpoint the client connects to (a malicious third-party service), by compromising a legitimate SSE server the client trusts, or by executing a network-level MITM between the client and a server using plain HTTP. Applications using HTTPX2 exclusively for non-SSE requests, or those connecting only to internal SSE endpoints over TLS with strong certificate pinning, are not exploitable. No authentication is required from the attacker's perspective once endpoint control is established.

Impact

The CVSS 3.1 vector CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H accurately reflects the threat model: the attack is network-delivered and requires no privileges, but AC:H captures the non-trivial prerequisite that the attacker must control or have compromised the SSE endpoint the client connects to. This is a meaningful barrier - the vulnerability cannot be triggered by a passive observer or a random internet scanner, but by a malicious server operator or a successful MITM or supply-chain compromise of a trusted SSE service. The impact is purely availability: CPU saturation of a worker thread or event loop with no confidentiality or integrity consequences. No KEV listing and no public exploit code have been identified. Even a mid-sized development team in kalisz running httpx2-powered microservices against external SSE feeds should treat upgrading to 2.10.0 as standard maintenance rather than emergency response, because real-world risk is gated on the ability to serve a crafted SSE response to the client. Applications that connect exclusively to internal, trusted SSE endpoints face substantially lower residual risk than those proxying or aggregating external SSE sources.

Exploit ScenarioDerived

An attacker operates a malicious HTTP server (or performs MITM on a connection to a trusted SSE service) and accepts the client's SSE request. The server returns a valid text/event-stream response and begins streaming a single SSE event whose data line is tens of kilobytes long, delivered in thousands of one-byte chunks. Each chunk causes _SSELineDecoder.decode() to rescan the entire accumulated buffer, and with a 100 KB line split across 100,000 chunks the total character operations reach approximately 5 × 10⁹, consuming the target process's CPU for an extended period and blocking all other processing in the same thread or event loop.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.3% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Sep 02, 2026

Quadratic CPU exhaustion in HTTPX2's Server-Sent Events parser allows a malicious or compromised SSE endpoint to deny service to Python applications using httpx2.Client.sse() or httpx2.AsyncClient.sse() in versions 2.5.0 through 2.9.x. The _SSELineDecoder.decode() method in _sse.py repeatedly copies and rescans its entire in-memory buffer each time a new chunk arrives for an unterminated line, producing O(n²) processing work proportional to the length of the crafted line. A crafted stream can consume excessive CPU, blocking a synchronous worker thread indefinitely or starving an asynchronous event loop. No public exploit identified at time of analysis; a vendor-released patch is available in version 2.10.0.

RemediationAI

Upgrade to HTTPX2 version 2.10.0, which is the vendor-released patch confirmed by the tagged GitHub release at https://github.com/pydantic/httpx2/releases/tag/v2.10.0 and the associated commit cbfc0e04ef6507da29ccbb3b9c2e5b23dd693414. Version 2.10.0 caps per-event buffering at 1 MiB by default and raises SSEError when the limit is exceeded. The cap can be tuned via the max_event_size parameter on .sse() - increasing it above the default raises exposure to larger payloads, while setting max_event_size=None disables the guard entirely and should be avoided. For applications that cannot upgrade immediately, restricting .sse() usage to internal or fully-trusted SSE endpoints and enforcing network egress controls that prevent connections to arbitrary external SSE servers will reduce the attack surface. No per-request workaround exists in versions prior to 2.10.0 without patching the library.

Affected VersionsENISA

httpx2 2.5.0, < 2.10.0

Affected Packages

pypi httpx2 fix: 2.10.0

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in pypi

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

HTTPX2 (CPE cpe:2.3:a:pydantic:httpx2:*:*:*:*:*:*:*:*), developed by the pydantic organization, is a next-generation Python HTTP client with built-in Server-Sent Events support. The SSE parser is implemented across _sse.py (_SSELineDecoder, _SSEDecoder, EventSource) and exposed via the .sse() context manager on both the synchronous Client and asynchronous AsyncClient. The root cause is CWE-407 (Inefficient Algorithmic Complexity): _SSELineDecoder.decode() was not bounding the buffer it accumulates for an in-progress (unterminated) line, and each new chunk triggered a full rescan of the accumulated text. Because work scales as O(n²) with line length, an endpoint that sends one extremely long line fragmented across many small chunks can drive CPU consumption to impractical levels. The fix in 2.10.0 introduces a DEFAULT_MAX_EVENT_SIZE_BYTES constant of 1 MiB, a per-event byte counter in _SSEDecoder, and a check_pending() method on EventSource that also counts bytes buffered for the current unterminated line, raising SSEError when the threshold is exceeded.

Know when Httpx2 gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (GitHub_M) PRIMARY 5.9 MEDIUM
AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H
vuln.today AI 5.9 MEDIUM

AC:H reflects mandatory endpoint control by the attacker; A:H captures full event-loop starvation with no confidentiality or integrity impact.

3.1 AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H
4.0 AV:N/AC:H/AT:N/PR:N/UI:N/VC:N/VI:N/VA:H/SC:N/SI:N/SA:N
Red Hat 5.9 MEDIUM

Primary rating from Vendor (GitHub_M).

CVSS VectorVendor: GitHub_M

Attack Vector
Network
Attack Complexity
High
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
None
Availability
High

Lifecycle Timeline

1
Patch available
Sep 02, 2026 - 19:17 EUVD

DescriptionCVE.org

HTTPX2 is a next generation HTTP client for Python. From 2.5.0 until 2.10.0, the HTTPX2 Server-Sent Events parser in src/httpx2/httpx2/_sse.py repeatedly copies and rescans buffered text in _SSELineDecoder.decode() when an attacker-controlled or compromised SSE endpoint splits one unterminated line across many response chunks. The behavior affects httpx2.Client.sse() and httpx2.AsyncClient.sse(), and the total processing work grows quadratically with the line length, allowing a crafted stream to consume excessive CPU and block a synchronous worker or asynchronous event loop. This issue is fixed in version 2.10.0.

Threat Intelligence Overview

EPSS Score
0.3%
Top 76% exploitable
Prevalence
Low
newer Python HTTP library, limited production adoption versus httpx
Threat Intel
1
1 source
Social Media
1
Sightings
Data Quality
7 sources
Confidence: High
EUVD NVD CVE.org EPSS Vulnrichment GHSA Vendor CIRCL GitHub VulDB

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.3%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Scheduled
Exploitation
None
System Exposure· derived
Open
Automatable
No
Human Impact· derived
Medium
Technical Impact
Partial

Priority Score

30
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +30
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Vendor StatusVendor

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy