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



CVE-2026-12151

CVE-2026-12151: Denial of Service via Uncontrolled Fragment Buffering in Undici WebSocket Client

Amit Schendel
Amit Schendel
Senior Security Researcher

Jun 19, 2026·7 min read·168 visits

Executive Summary (TL;DR)

The undici WebSocket client does not limit the number of continuation frames per message, enabling a malicious server to crash the client process via heap exhaustion using infinite zero-byte fragments.

A high-severity denial of service vulnerability in the undici WebSocket client (CVE-2026-12151) arises from uncontrolled memory consumption. Although undici validates individual fragment sizes against a cumulative payload limit, it fails to cap the total number of frames in a single message stream. This allows a rogue or compromised WebSocket server to send an infinite sequence of small or empty continuation frames, causing unbounded memory allocation and eventual heap exhaustion on the client process.

Vulnerability Overview

The WebSocket protocol (RFC 6455) permits message fragmentation to facilitate the transmission of data streams whose total size is unknown at the start of transmission. The OpenJS Foundation's undici, a high-performance HTTP/1.1, HTTP/2, and WebSocket client for Node.js, implements this specification. To defend against resource exhaustion, undici allows developers to enforce a cumulative payload size limit via the maxPayloadSize parameter.

However, a critical security boundary is missed in the implementation of the WebSocket frame parser. While undici correctly aggregates and checks the total payload size of incoming fragments, it does not enforce any restriction on the absolute quantity of individual frames comprising a single WebSocket message. This gap exposes applications utilizing undici to endpoint denial of service.

An attacker capable of controlling the WebSocket server, or performing a machine-in-the-middle injection on unencrypted channels, can exploit this design flaw. By sending an ongoing stream of small or empty continuation frames, the attacker bypasses the cumulative payload limit check. The client continues to accept these frames, eventually exhausting available heap space and crashing the Node.js runtime environment.

Root Cause Analysis

To understand the vulnerability, it is necessary to examine how RFC 6455 structure matches memory allocation patterns in V8. A fragmented WebSocket message begins with an initial frame containing a specific data type opcode (0x1 for text, 0x2 for binary) and a FIN bit set to 0. Subsequent frames carry the continuation opcode (0x0) and a FIN bit of 0, until the final frame arrives with a FIN bit of 1.

In undici, as each continuation frame is parsed, the cumulative size of the payload is updated using the calculation:

$$\text{Cumulative Payload Size} = \sum_{i=1}^{n} \text{payloadLength}(\text{fragment}_i)$$

If this sum exceeds the configured maxPayloadSize, the client halts execution and terminates the connection. This algorithm assumes that a payload-size ceiling is sufficient to constrain memory utilization. However, it fails to account for metadata overhead.

For every frame processed, the underlying engine must allocate memory to track fragment-specific metadata, references, and buffers. If an adversary sends frames where the payload size is zero, the mathematical summation remains well below the maxPayloadSize threshold. The physical heap allocation, however, grows linear to the frame count. The V8 garbage collector cannot free these allocations because they are actively referenced within undici's internal queue waiting for the final frame, which never arrives.

Vulnerable vs. Patched Code Path

The flaw resides within the logic of the frame parser. Below is a representation of the vulnerable parsing pattern, illustrating how frames are appended without tracking the overall fragment count:

// Vulnerable logic in frame processing
class WebSocketParser {
  constructor(options) {
    this.maxPayloadSize = options.maxPayloadSize || 1048576;
    this._fragments = [];
    this._currentPayloadSize = 0;
  }
 
  onFrame(frame) {
    // Validate cumulative payload size
    this._currentPayloadSize += frame.payloadLength;
    if (this._currentPayloadSize > this.maxPayloadSize) {
      this.destroy(new Error('Max payload size exceeded'));
      return;
    }
 
    // Unbounded storage of frame references
    this._fragments.push(frame);
 
    if (frame.fin) {
      const fullMessage = this.reassemble(this._fragments);
      this.emit('message', fullMessage);
      this.reset();
    }
  }
}

To remediate the vulnerability, the frame parser must introduce a counter representing the total number of frames received for the active message, or explicitly enforce a maximum frame limit. The patched logic below demonstrates how a limit is enforced on the total count of fragments, mitigating the allocation loophole:

// Patched logic incorporating fragment limit validation
class WebSocketParser {
  constructor(options) {
    this.maxPayloadSize = options.maxPayloadSize || 1048576;
    this.maxFragmentCount = options.maxFragmentCount || 1000; // Enforced limit
    this._fragments = [];
    this._currentPayloadSize = 0;
  }
 
  onFrame(frame) {
    // Validate cumulative payload size
    this._currentPayloadSize += frame.payloadLength;
    if (this._currentPayloadSize > this.maxPayloadSize) {
      this.destroy(new Error('Max payload size exceeded'));
      return;
    }
 
    // Prevent unbounded array growth
    if (this._fragments.length >= this.maxFragmentCount) {
      this.destroy(new Error('Max fragment count exceeded'));
      return;
    }
 
    this._fragments.push(frame);
 
    if (frame.fin) {
      const fullMessage = this.reassemble(this._fragments);
      this.emit('message', fullMessage);
      this.reset();
    }
  }
}

By checking both the physical size of the data and the total structure count, the library prevents attackers from inducing unbounded memory states.

Exploitation Methodology

An attacker exploiting CVE-2026-12151 requires the targeted undici client to initiate a connection to an attacker-controlled WebSocket server, or a server that is vulnerable to downstream request hijacking. Once the WebSocket connection is established, the server initiates an infinite stream of empty continuation frames.

The attack vector is illustrated in the sequence diagram below:

Because the payload size of each individual frame is zero, the cumulative size calculation never triggers a threshold violation. However, the client allocates a small amount of memory in the heap for each frame's metadata and object wrapper. Over thousands of cycles, this leads to an Out-of-Memory condition.

Impact Assessment

The security impact of CVE-2026-12151 is classified as High, with a CVSS v3.1 Base Score of 7.5. The primary consequence is the total loss of availability for the application utilizing the undici client. In Node.js environments, an Out-of-Memory error results in a fatal error, which abruptly terminates the entire process.

If the affected Node.js service is responsible for handling critical backend integrations, message consumption, or user-facing APIs, the crash results in an immediate service disruption. Unless robust external process monitoring (such as systemd, PM2, or Kubernetes Pod orchestrators) is in place to auto-restart the process, the denial of service remains permanent.

Even with automated recovery mechanisms, an attacker can continuously exploit the loop upon client reconnection, creating a persistent denial of service state. This attack requires zero privileges and no user interaction, making it highly attractive for attackers targeting webhook handlers or client-side integrations that connect to user-supplied URLs.

Remediation and Mitigation

To remediate CVE-2026-12151, developers must upgrade the undici package to the designated non-vulnerable versions. No configuration workarounds exist that can mitigate this flaw within the affected versions, as the vulnerability lies deep within the framing state machine.

Upgrade paths based on major version lines are as follows:

  • If using undici v6.x: Upgrade to v6.26.0 or later.
  • If using undici v7.x: Upgrade to v7.28.0 or later.
  • If using undici v8.x: Upgrade to v8.5.0 or later.

To verify the current version of undici installed in a project, run the following npm CLI command:

npm ls undici

If indirect or transient dependencies pull in a vulnerable version, developers can enforce resolutions in their package.json using NPM overrides or Yarn resolutions to force the safe version.

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
EPSS Probability
0.28%
Top 80% most exploited

Affected Systems

undici WebSocket clientNode.js applications utilizing undici

Affected Versions Detail

Product
Affected Versions
Fixed Version
undici
OpenJS Foundation
>= 6.17.0 < 6.26.06.26.0
undici
OpenJS Foundation
>= 7.0.0 < 7.28.07.28.0
undici
OpenJS Foundation
>= 8.0.0 < 8.5.08.5.0
AttributeDetail
CWE IDCWE-400, CWE-770
Attack VectorNetwork (AV:N)
CVSS v3.1 Score7.5 (High)
EPSS Score0.00284 (Percentile: 19.97%)
ImpactDenial of Service (OOM Crash)
Exploit StatusPoC available, no active wild exploitation
KEV StatusNot listed

MITRE ATT&CK Mapping

T1499Endpoint Denial of Service
Impact
CWE-400
Uncontrolled Resource Consumption

The software does not control or limit the amount of resources (in this case, memory) that can be consumed when handling an incoming stream of WebSocket fragments.

Vulnerability Timeline

CVE-2026-12151 Advisory Published by OpenJS Foundation
2026-06-17
CVE-2026-12151 Designated and Published to the NVD
2026-06-17
Patched Versions (6.26.0, 7.28.0, 8.5.0) Released on npm Registry
2026-06-17

References & Sources

  • [1]GHSA-vxpw-j846-p89q
  • [2]OpenJS Foundation Security Advisories
  • [3]CVE-2026-12151 Record
  • [4]NVD - CVE-2026-12151

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

•about 5 hours ago•CVE-2026-63402
5.9

CVE-2026-63402: Prototype-Chain Traversal and Shared Built-in Corruption in i18next

CVE-2026-63402 is a prototype-chain traversal and shared built-in object corruption vulnerability in the i18next internationalization framework for JavaScript prior to version 26.3.4. The flaw resides in the deepExtend utility function within src/utils.js, which uses the JavaScript 'in' operator to verify property existence on target objects. When an application passes untrusted resource bundles to i18next.addResourceBundle() with both the deep and overwrite parameters set to true, an attacker can traverse into inherited methods on Object.prototype and overwrite properties on shared built-in function objects, causing process-wide denial of service.

Amit Schendel
Amit Schendel
3 views•10 min read
•about 6 hours ago•CVE-2026-58262
7.1

CVE-2026-58262: BLS Signature Quorum Bypass via PubKeysBitmap Padding Bits in Klever-Go

CVE-2026-58262 (tracked internally as KLR-04 and via GitHub Security Advisory GHSA-f9h7-4mmq-vgcq) is a cryptographic verification and consensus quorum bypass vulnerability in Klever-Go (`klever-io/klever-go`), the Go implementation of the Klever blockchain protocol. Prior to version 1.7.20, the block header signature verification logic (`HeaderSigVerifier.verifyConsensusSize`) counts all set bits across the entire `PubKeysBitmap` byte slice toward the required two-thirds validator quorum without masking or validating unused trailing padding bits in the final byte. Because the underlying Boneh-Lynn-Shacham (BLS) multi-signature verification function (`blsMultiSigner.Verify`) iterates strictly over the indices of configured validator public keys, it ignores any bits set at indices beyond the active consensus group size. When the consensus group size is not an exact multiple of 8, a compromised or malicious block producer can set these unused trailing padding bits to artificially inflate the apparent signer count by up to 7 signatures, enabling blocks with fewer genuine validator signatures than required by the protocol to pass consensus validation.

Alon Barad
Alon Barad
3 views•14 min read
•about 7 hours ago•CVE-2026-77423
7.5

CVE-2026-77423: Regular Expression Denial of Service (ReDoS) in JLine Built-in Less Viewer

CVE-2026-77423 is a Regular Expression Denial of Service (ReDoS) vulnerability in the built-in less viewer of the JLine Java library (versions 3.0.0 prior to 3.30.15, and 4.0.0 prior to 4.3.1). The org.jline.builtins.Less class passes user-supplied search and display-filter patterns directly to Java's standard backtracking regular expression engine without complexity validation or execution timeouts. An attacker with access to an interactive JLine session can submit patterns containing nested quantifiers, causing catastrophic backtracking that consumes 100% of a CPU core and blocks the session thread indefinitely. In network-facing deployments such as SSH or Telnet administration consoles, repeated exploitation across concurrent sessions can exhaust bounded worker thread pools and result in a complete denial of service.

Alon Barad
Alon Barad
3 views•10 min read
•about 8 hours ago•CVE-2026-63492
8.1

CVE-2026-63492 (Duplicate of CVE-2026-63304): OS Command Injection in WWBN AVideo Standalone API

CVE-2026-63492 is a rejected CVE identifier originally assigned by GitHub for an OS command injection vulnerability in WWBN AVideo (formerly YouPHPTube) up to version 29.0. It was rejected as a duplicate of the canonical identifier CVE-2026-63304 (tracked under GHSA-j44m-77cc-p3cc). The flaw resides in the listFFmpegProcesses() function within plugin/API/standAlone/functions.php, which interpolates unsanitized user parameters directly into a single-quoted shell pipeline executed via PHP's exec() function. Attackers capable of crafting a valid AES-256-CBC encrypted API payload can break out of the single-quoted context and execute arbitrary operating system commands as the web-server user.

Amit Schendel
Amit Schendel
4 views•9 min read
•about 9 hours ago•CVE-2026-63476
4.3

CVE-2026-63476: Unbounded Memory Allocation and Denial of Service in isomorphic-git Packfile Delta Parser

CVE-2026-63476 is an uncontrolled resource consumption vulnerability in isomorphic-git prior to version 1.38.6. When parsing Git packfile delta objects during clone or fetch operations, the applyDelta utility reads an untrusted targetSize integer from the delta stream header and passes it directly to Buffer.alloc(). A malicious remote Git server or man-in-the-middle attacker can supply a delta header specifying a targetSize of approximately 2 GB with minimal actual payload data. Because Buffer.alloc() reserves off-heap memory in Node.js, this bypasses standard V8 heap limits and results in immediate out-of-memory termination or sustained memory retention.

Amit Schendel
Amit Schendel
5 views•10 min read
•about 10 hours ago•CVE-2026-63410
5.9

CVE-2026-63410: Compiler-Induced Timing Side-Channel in secp256k1-native Scalar Multiplication

CVE-2026-63410 (GHSA-vp2j-gqfm-r3cf) is a compiler-induced timing side-channel vulnerability in the secp256k1-native Ruby C extension. When compiled with GCC 14.x or 15.x at optimization level -O2, the compiler reconstructs boolean predicates from branchless bitwise multiplexer routines and emits secret-dependent conditional jump instructions (je/jne). During elliptic curve scalar multiplication in the Montgomery ladder, these conditional branches create observable execution timing variations correlated with individual bits of secret private keys or signing nonces.

Alon Barad
Alon Barad
3 views•12 min read