CVE-2026-1526: Undici WebSocket Client Suffers from Unbounded Memory Consumption Vulnerability

undici Updated 13 Mar 2026

Summary

13/03/2026
Yes i
High
7.5

CVE-2026-1526: Undici has Unbounded Memory Consumption in WebSocket permessage-deflate Decompression. Affects undici across 2 version ranges.

< 6.24.0 >= 7.0.0, < 7.24.0

Fixed in 6.24.0 or 7.24.0, depending on the release line you run. How to fix ↓

Free scan

Check if this vulnerability affects your application

Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.

Check my app free

No signup required · Results in about 60 seconds

Upload your dependency manifest or SBOM

Drag & drop your file here or

Java Javascript PHP Python Go Rust Ruby Dart C/C++ Elixir CycloneDX SPDX

Upload a supported dependency manifest or SBOM. No installation or source-code access required.

See supported files and SBOM formats
SBOM sbom.json · bom.json · bom.xml · *.spdx.json · *.cdx.json · *.cdx.xml
Java pom.xml · gradle.lockfile · buildscript-gradle.lockfile
Javascript package-lock.json · yarn.lock · pnpm-lock.yaml
PHP composer.lock
Python poetry.lock · requirements.txt · Pipfile.lock
Go go.mod
Rust Cargo.lock
Ruby Gemfile.lock
Dart pubspec.lock
C/C++ conan.lock
Elixir mix.lock
Enter your work email to receive your report link.

Verify your email to view the full report and start 30 days of continuous monitoring. No credit card required.

Sponsored MarkAI Find prospects already talking about the problem you solve AI watches the communities your customers use to find qualified prospects, then alerts you when a conversation is worth joining. See MarkAI

Background

Undici is a popular HTTP/1.1 client designed for Node.js, known for its performance and efficiency. It provides a lightweight and modern API for making HTTP requests and is often used in applications that require high throughput. However, the undici WebSocket client has a critical vulnerability that can lead to denial-of-service attacks, specifically during the decompression of frames negotiated with the permessage-deflate extension.

Vulnerability Detail

The vulnerability arises from the PerMessageDeflate.decompress() method in the undici WebSocket client, which decompresses incoming compressed frames without enforcing a limit on the size of the decompressed data. This allows a malicious WebSocket server to send a small compressed frame, known as a 'decompression bomb,' that expands to an excessively large size in memory. As a result, the Node.js process can exhaust available memory, leading to crashes or unresponsiveness. The impact includes remote denial of service against any Node.js application using undici's WebSocket client, with a single compressed frame of approximately 6 MB potentially decompressing to over 1 GB, bypassing V8 heap limits and rendering application-level mitigations ineffective.

How To Fix

Latest published version: 8.12.3 as of 22 Oct 2026

npm install undici@8.12.3

Upgrading to it may include breaking changes; the versions below are the minimum fixed release for this vulnerability.

If you can't move to the latest

The minimum fixed version depends on the release line you run.

  • < 6.24.0 6.24.0
    npm install undici@6.24.0
  • >= 7.0.0, < 7.24.0 7.24.0
    npm install undici@7.24.0

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Workaround

No workarounds are available for this vulnerability, as the decompression occurs before message delivery, making it impossible to mitigate at the application level.

Conclusion

In summary, the undici WebSocket client is vulnerable to a denial-of-service attack due to unbounded memory consumption during permessage-deflate decompression. Users are strongly advised to upgrade to the patched versions to mitigate this risk.

See every vulnerability recorded for undici →

Share this vulnerability

FAQ

The vulnerability allows for unbounded memory consumption during the decompression of WebSocket frames, leading to potential denial-of-service attacks.

You can check if your application is affected by using Vulert, which monitors and alerts for open-source vulnerabilities in real-time. Visit Vulert Scanner to check your application without any signup.

The consequences include potential crashes or unresponsiveness of Node.js applications using the undici WebSocket client due to memory exhaustion.

Unfortunately, there are no effective workarounds available for this vulnerability, as it requires an upgrade to the patched versions.

The CVSS score of this vulnerability is 7.5, indicating a high severity level.

Related vulnerabilities

Recent vulnerabilities recorded for undici.

How To Fix

Latest published version: 8.12.3 as of 22 Oct 2026

npm install undici@8.12.3

Upgrading to it may include breaking changes; the versions below are the minimum fixed release for this vulnerability.

If you can't move to the latest

The minimum fixed version depends on the release line you run.

  • < 6.24.0 6.24.0
    npm install undici@6.24.0
  • >= 7.0.0, < 7.24.0 7.24.0
    npm install undici@7.24.0

Tip — Not sure which release line you're on? Vulert can find the fix for the version you are using. Scan free →

Subscribe to Vulert on Telegram
Daily digest of new CVEs, critical and high severity, affected packages and fixes — plus a weekly roundup.
Join the channel →
Help improve this record
Report an issue or send feedback