# CVE-2026-48779: websockets ws memory exhaustion DoS via small fragments

Source: https://junglewise.ai/threats/cve-2026-48779-websockets-ws-memory-exhaustion-dos-via-small-fragments  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2026-06-17. Updated: 2026-06-20  
License: CC BY 4.0 with a link back

CVE-2026-48779 · Severity: high · CVSS 7.5 · Published 2026-06-17

The 'ws' library, a popular tool for handling real-time WebSocket communications in Node.js applications, is vulnerable to a denial-of-service attack. An attacker can send a flood of specially crafted small data fragments that force the server to consume excessive amounts of memory. This can lead to the application crashing or becoming unresponsive, potentially disrupting services for all users.

Technologies: [ws (npm)](https://junglewise.ai/threats/technologies/ws). Vendors: [npm](https://junglewise.ai/threats/vendors/npm).

## Quick answers

**Is CVE-2026-48779 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2026-48779 being exploited in the wild.

**How severe is CVE-2026-48779?** High severity, with a CVSS score of 7.5, published 17 June 2026.

**Which products and versions are affected?** ws (npm) SEMVER:introduced=1.1.0,fixed=5.2.5.

**Is there a fix for CVE-2026-48779?** Yes. ws (npm): upgrade to 5.2.5 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2026-48779 attacked?** It is attacked over the network, in a software library.

**Am I affected by CVE-2026-48779?** Check whether you run ws (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- ws (npm): upgrade to 5.2.5 or later

  ```sh
  npm install ws@5.2.5
  ```


## Technical details

The 'ws' library for Node.js is vulnerable to uncontrolled resource consumption (CWE-400/CWE-770). An attacker can exploit this by sending a high volume of exceptionally small WebSocket fragments and data chunks. While the total data size may remain under the documented 'maxPayload' limit, the library allocates structural wrappers for each fragment. This overhead causes the process to consume significantly more memory than expected, eventually leading to an Out of Memory (OOM) error and process termination. The vulnerability is reachable over the network without authentication. Fixes are available in versions 5.2.5, 6.2.4, 7.5.11, and 8.21.0.

## Affected products

- websockets ws >= 1.1.0, < 5.2.5; >= 6.0.0, < 6.2.4; >= 7.0.0, < 7.5.11; >= 8.0.0, < 8.21.0

## Identifiers

- CVE-2026-48779
- GHSA-96hv-2xvq-fx4p

## Timeline

- 2026-05-22: advisory: GitHub Security Advisory GHSA-96hv-2xvq-fx4p published
- 2026-06-17: disclosed: CVE-2026-48779 published to NVD

## References

- [https://github.com/websockets/ws/commit/86d3e8a5fb0246ed373860c5fbb0de88824a27f7](https://github.com/websockets/ws/commit/86d3e8a5fb0246ed373860c5fbb0de88824a27f7)
- [https://github.com/websockets/ws/commit/b5372ac67bb97a773727b8e9f5035a8123556d53](https://github.com/websockets/ws/commit/b5372ac67bb97a773727b8e9f5035a8123556d53)
- [https://github.com/websockets/ws/commit/bca91adf15677e47dbe4f959653452727be28b94](https://github.com/websockets/ws/commit/bca91adf15677e47dbe4f959653452727be28b94)
- [https://github.com/websockets/ws/commit/fd36cd864fcdf62a08273a99e19a7d975401fee8](https://github.com/websockets/ws/commit/fd36cd864fcdf62a08273a99e19a7d975401fee8)
- [https://github.com/websockets/ws/security/advisories/GHSA-96hv-2xvq-fx4p](https://github.com/websockets/ws/security/advisories/GHSA-96hv-2xvq-fx4p)

## Related threats

- [websockets ws uninitialized memory disclosure in websocket.close](https://junglewise.ai/threats/cve-2026-45736-websockets-ws-uninitialized-memory-disclosure-in-websocket-close)
- [ws ReDoS vulnerability in Sec-Websocket-Protocol header parsing](https://junglewise.ai/threats/cve-2021-32640-ws-redos-vulnerability-in-sec-websocket-protocol-header-parsing)
- [ws WebSocket denial of service in Sec-WebSocket-Extensions parsing](https://junglewise.ai/threats/ws-websocket-denial-of-service-in-sec-websocket-extensions-parsing-199b7f5b)
- [ws excessive websocket payload denial of service](https://junglewise.ai/threats/cve-2016-10542-ws-excessive-websocket-payload-denial-of-service)
- [websockets ws remote memory disclosure via uninitialized buffers](https://junglewise.ai/threats/cve-2016-10518-websockets-ws-remote-memory-disclosure-via-uninitialized-buffers)
