http4s WebSocket decoder accepts negative length, causing infinite decode loop
Package Affected versions Patched versions Description WebSocket's FrameTranscoder.bodyLength reads a 64-bit extended payload length and rejects only values greater than Integer.MAX_VALUE.
A negative
Package
org.http4s:http4s-core_2.12 (Maven)Affected versions
< 0.23.35Patched versions
0.23.35 org.http4s:http4s-core_2.13 (Maven) < 0.23.35 >= 1.0.0-M2, < 1.0.0-M47 0.23.35 1.0.0-M47 org.http4s:http4s-core_3 (Maven) < 0.23.35 >= 1.0.0-M2, < 1.0.0-M47 0.23.35 1.0.0-M47Description
WebSocket's FrameTranscoder.bodyLength reads a 64-bit extended payload length and rejects only values greater than Integer.MAX_VALUE. A negative length passes validation. This makes the decoder return an empty frame without advancing the buffer, and drives the decode loop into an uninterruptible infinite loop. This pins a CPU and grows an ArrayBuffer unbounded.
The defective transcoder is in http4s-core, but the denial of service manifests with http4s-ember-server.
Impact
A single frame can pin one worker at 100% CPU in an uninterruptible loop and grows memory unboundedly, resulting in a denial of service.
Preconditions
- Server exposes a WebSocket endpoint via an Ember server.
- Attacker completes the WebSocket handshake.
Workarounds
None
Resources
- RFC 6455 §5.2: Base Framing Protocol
References
- GHSA-3j86-pj9g-jchr
- https://nvd.nist.gov/vuln/detail/CVE-2026-69210
- http4s/http4s@c7d3ef9
- https://github.com/http4s/http4s/releases/tag/v0.23.35
- https://github.com/http4s/http4s/releases/tag/v1.0.0-M47
Severity
High CVSS overall score This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS). / 10CVSS v3 base metrics
Attack vector Network Attack complexity Low Privileges required None User interaction None Scope Unchanged Confidentiality None Integrity None Availability High CVSS v3 base metrics Attack vector: More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability. Attack complexity: More severe for the least complex attacks. Privileges required: More severe if no privileges are required. User interaction: More severe when no user interaction is required. Scope: More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope. Confidentiality: More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user. Integrity: More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user. Availability: More severe when the loss of impacted component availability is highest. CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:HEPSS score
Exploit Prediction Scoring System (EPSS) This score estimates the probability of this vulnerability being exploited within the next 30 days. Data provided by FIRST. (45th percentile)Weaknesses
Weakness CWE-835Loop with Unreachable Exit Condition
The product contains an iteration or loop with an exit condition that cannot be reached, i.e., an infinite loop. Learn more on MITRE. Weakness CWE-1284Improper Validation of Specified Quantity in Input
The product receives input that is expected to specify a quantity (such as size or length), but it does not validate or incorrectly validates that the quantity has the required properties. Learn more on MITRE.CVE ID
CVE-2026-69210GHSA ID
GHSA-3j86-pj9g-jchrSource code
http4s/http4sCredits
-
samspills Remediation reviewer
-
morgen-peschke Remediation reviewer
Uh oh!
There was an error while loading. Please reload this page.
See something to contribute? Suggest improvements for this vulnerability.