CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



GHSA-7PPR-R889-MCF2

GHSA-7PPR-R889-MCF2: Unbounded WebSocket Message Aggregation in http4s-blaze-server leads to Denial of Service

Alon Barad
Alon Barad
Software Engineer

Jul 25, 2026·5 min read·34 visits

Executive Summary (TL;DR)

Unbounded WebSocket message aggregation in http4s-blaze-server allows unauthenticated remote attackers to crash the server with an OutOfMemoryError via a stream of tiny continuation fragments.

An uncontrolled resource consumption vulnerability exists in the Scala-based http4s-blaze-server package of the http4s/blaze library. The vulnerability allows remote, unauthenticated attackers to cause an Out of Memory Error (OOM) and JVM crash by streaming a continuous sequence of small or empty WebSocket continuation frames with the FIN bit set to 0. This bypasses typical payload size checks because of the JVM's per-object allocation overhead, leading to rapid heap exhaustion with minimal network bandwidth.

Vulnerability Overview

An uncontrolled resource consumption vulnerability exists in the http4s-blaze-server component of the Scala HTTP library ecosystem. The vulnerability is classified under CWE-400 (Uncontrolled Resource Consumption) and CWE-770 (Allocation of Resources Without Limits or Throttling).

The vulnerability is located within the server's WebSocket message aggregation system. WebSocket connections that use message fragmentation can be manipulated by an unauthenticated remote attacker to consume unbounded amounts of heap memory on the host Java Virtual Machine (JVM). This resource exhaustion can occur regardless of the actual data payload size transmitted over the network.

Because the underlying library did not impose a limitation on the number of accumulated fragments or the overall size of buffered payloads, it created a severe vector for remote Denial of Service (DoS) attacks. The threat can be realized through low-bandwidth streams of small frames, making traditional traffic rate-limiting or firewall payload checks ineffective.

Root Cause Analysis

The root cause of this vulnerability lies in the implementation of the WSFrameAggregator class inside the http4s-blaze-server packet pipeline. This component is designed to reconstruct fragmented WebSocket frames according to RFC 6455 specifications.

RFC 6455 permits a WebSocket message to be split into multiple frames starting with a non-final frame (FIN=0) and followed by any number of continuation frames (opcode 0x0, FIN=0). The aggregation layer stores incoming fragments within an internal Scala queue called the Accumulator until a frame with the FIN bit set to 1 is received.

Two critical flaws occurred within this processing model. First, there was no cap on the maximum cumulative payload size of aggregated messages. Second, and more importantly, each incoming frame requires the allocation of several JVM metadata objects, including a WebSocketFrame instance, an internal ByteVector wrapper, and list elements within Scala's mutable.Queue. This metadata represents approximately 64 bytes of object overhead per frame on the JVM heap. An attacker can stream millions of 0-byte continuation frames to exhaust heap memory using minimal network transit.

Code Analysis

Before the patch, WSFrameAggregator lacked size checks during its accumulation cycle, allowing the internal Accumulator queue to grow without bounds. This section demonstrates how the patch resolves this memory leak.

// Patched message size validation helper
private[this] def messageTooLarge(next: WebSocketFrame): Boolean = {
  val charged = accumulator.length.toLong + next.length.toLong +
    (accumulator.frames.toLong + 1L) * WSFrameAggregator.FragmentOverheadBytes
  maxMessageSize > 0 && charged > maxMessageSize.toLong
}

To address object metadata expansion, the patch charges a virtual penalty of 64 bytes (FragmentOverheadBytes) for each accumulated fragment. This prevents the queue from expanding indefinitely even when receiving empty payloads. When the computed size exceeds maxMessageSize, the accumulator is purged, and a WebSocketMessageTooLargeException is thrown.

Additionally, the patch links the maximum size thresholds between the frame aggregator and the low-level frame decoder, preventing single-frame buffer exploits:

// Aligning aggregator and decoder bounds
val wsMaxMessageSize =
  maxBufferSize.getOrElse(WSFrameAggregator.DefaultMaxMessageSize)
...
    .prepend(new WSFrameAggregator(wsMaxMessageSize))
    .prepend(new WebSocketDecoder(wsMaxMessageSize))

Exploitation Methodology

Exploitation of GHSA-7PPR-R889-MCF2 can be executed by an unauthenticated remote adversary with network access to a WebSocket endpoint exposed by an affected http4s-blaze-server instance.

The attack flow is executed as follows:

  1. Establish a standard TCP connection to the server.
  2. Initiate a standard WebSocket upgrade handshake to negotiate the protocol.
  3. Send an initial frame (such as a Text frame) with the FIN bit set to 0.
  4. Continually transmit a stream of continuation frames (opcode 0x0) with the FIN bit set to 0 and minimal or 0-byte payloads.

By withholding the final frame (FIN=1), the attacker ensures that the server's WSFrameAggregator maintains state and continues to allocate memory structures on the heap. This causes the JVM to consume heavy CPU cycles attempting garbage collection before crashing with an OutOfMemoryError.

Impact Assessment

The impact of a successful exploit against GHSA-7PPR-R889-MCF2 is high. Since the http4s-blaze-server process runs inside a single JVM container, an OutOfMemoryError will terminate the active thread pool or cause the JVM process to crash. This completely disrupts service for all active users.

Because the vulnerability requires no special privileges and does not depend on specific application states or configurations, any endpoint supporting WebSockets is fully exposed. The CVSS score for this vulnerability is assessed at 7.5 (High) under vector string CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H.

Because GHSA-7PPR-R889-MCF2 is an advisory published within the GitHub Advisory Database without a matching CVE ID, organizations relying on basic CVE scanner databases may fail to recognize the exposure of their software. This necessitates active dependency audits of all Scala microservices using the http4s backend.

Remediation and Mitigation

To remediate the vulnerability, users must upgrade their dependencies to one of the patched versions: 0.23.18 or 1.0.0-M42. These releases configure WSFrameAggregator to use a default 4 MiB payload cap and apply the per-fragment overhead penalty.

If upgrading is not immediately possible, the following mitigations can reduce exposure:

  • Configure any downstream proxy, load balancer, or API gateway to throttle the duration or packet count of individual WebSocket connections.
  • Ensure that your application's BlazeServerBuilder is not configured with negative or zero limits, which will bypass the newly introduced security boundaries.
// Secure configuration example enforcing validation:
BlazeServerBuilder[IO]
  .bindHttp(8080, "0.0.0.0")
  .withMaxWebSocketBufferSize(4 * 1024 * 1024) // 4MB maximum buffer

Official Patches

http4sCore Aggregator Cap Fix

Fix Analysis (3)

Technical Appendix

CVSS Score
7.5/ 10
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Affected Systems

http4s-blaze-server

Affected Versions Detail

Product
Affected Versions
Fixed Version
http4s-blaze-server
http4s
< 0.23.180.23.18
http4s-blaze-server
http4s
< 1.0.0-M421.0.0-M42
AttributeDetail
CWE IDCWE-400
Attack VectorNetwork
CVSS7.5
ImpactDenial of Service (DoS)
Exploit StatusNone (PoC verified theoretically)
KEV StatusNot Listed

MITRE ATT&CK Mapping

T1499.004Endpoint Denial of Service: System Resource Exhaustion
Impact
CWE-400
Uncontrolled Resource Consumption

The product does not properly control the allocation and maintenance of a limited resource, enabling an actor to cause a resource depletion.

References & Sources

  • [1]GitHub Security Advisory GHSA-7PPR-R889-MCF2

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•2 minutes ago•CVE-2026-109619
9.2

CVE-2026-109619: Remote Code Execution in PHP Core via Stale Global State Memory Corruption (PHP2Shell)

CVE-2026-109619 (PHP2Shell) is a critical Use-After-Free vulnerability in the core PHP engine caused by improper global state cleanup during out-of-memory exception handling across persistent worker requests.

Alon Barad
Alon Barad
1 views•6 min read
•5 minutes ago•CVE-2026-113721
4.5

CVE-2026-113721: Unsafe Link Resolution in virtualenv File Generation

In Python virtualenv prior to version 21.14.9, activation script generators and configuration writers use Path.exists() before writing files. Because Path.exists() resolves symbolic links, it returns False for dangling symlinks. Consequently, virtualenv skips unlinking pre-planted symbolic links or hard links, writing data directly to target locations outside the intended virtual environment directory.

Amit Schendel
Amit Schendel
1 views•5 min read
•9 days ago•CVE-2026-87697
8.8

CVE-2026-87697: Untrusted Deserialization in .NET PresentationCore Clipboard Handling

A remote code execution vulnerability exists in Microsoft .NET due to untrusted data deserialization within the PresentationCore component. The flaw stems from implicit auto-conversion flags during clipboard data retrieval operations.

Alon Barad
Alon Barad
31 views•5 min read
•9 days ago•CVE-2026-70007
8.8

CVE-2026-70007: Out-of-Bounds Write Vulnerability in .NET Framework and WPF Subsystem

An out-of-bounds write vulnerability in Microsoft .NET Framework, .NET runtime, and Visual Studio allows unauthenticated remote attackers to execute arbitrary code via crafted pixel-shader bytecode or auto-converted clipboard payloads.

Amit Schendel
Amit Schendel
19 views•6 min read
•10 days ago•CVE-2026-70186
7.5

CVE-2026-70186: ASP.NET Core Denial of Service Vulnerability via Framework Deadlock

ASP.NET Core contains a thread deadlock vulnerability (CWE-833) that allows an unauthenticated remote attacker to cause a denial of service over the network by exhausting server thread pool resources.

Amit Schendel
Amit Schendel
18 views•5 min read
•10 days ago•CVE-2026-70035
8.8

CVE-2026-70035: Insecure Deserialization Remote Code Execution in Microsoft .NET Framework and .NET Runtime

CVE-2026-70035 is a high-severity Remote Code Execution (RCE) vulnerability in Microsoft .NET Framework, .NET runtime, and Visual Studio caused by improper handling during the deserialization of untrusted data (CWE-502). An unauthenticated attacker can execute arbitrary code within the context of the affected process by delivering a crafted serialized payload.

Amit Schendel
Amit Schendel
24 views•6 min read