Skip to content

fix: bump ws dependency from ^7.5.10 to ^8.21.1 (CVE-2026-48779) - #10817

Open
rajat2911 wants to merge 3 commits into
firebase:mainfrom
rajat2911:fix/bump-ws-to-8.21.1
Open

fix: bump ws dependency from ^7.5.10 to ^8.21.1 (CVE-2026-48779)#10817
rajat2911 wants to merge 3 commits into
firebase:mainfrom
rajat2911:fix/bump-ws-to-8.21.1

Conversation

@rajat2911

@rajat2911 rajat2911 commented Jul 20, 2026

Copy link
Copy Markdown

Summary

Bumps the ws direct dependency from ^7.5.10 to ^8.21.1 and aligns @types/ws in devDependencies from ^7.2.3 to ^8.18.1 to address CVE-2026-48779 — a remote memory exhaustion DoS vulnerability.

Closes #10816

Changes

Package Before After
ws ^7.5.10 ^8.21.1
@types/ws ^7.2.3 ^8.18.1

Vulnerability

  • CVE: CVE-2026-48779
  • Severity: High
  • Description: A high volume of tiny fragments and data chunks can be sent by a peer, using modest network traffic, to crash a ws server or client due to OOM.
  • Fixed in: ws@8.21.0 / ws@8.21.1

See: https://github.com/websockets/ws/releases/tag/8.21.0

Why ^7.5.10 doesn't help

The current ^7.5.10 range is forever locked to 7.x. The vulnerability fix landed in 8.21.0, so a major version bump is required — semver resolution will never pull in 8.x from a ^7.x range.

Compatibility

The ws 8.x API is backward-compatible for the usage patterns in this codebase (WebSocket.Server, ws.send(), ws.on("connection", ...)). No code changes are required beyond the version bumps in package.json.

Impact for consumers

Without this change, downstream users are forced to apply workarounds like npm overrides or yarn resolutions to avoid shipping vulnerable code — an unnecessary burden that an upstream fix eliminates.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the ws dependency in package.json to a new major version (^8.21.1). The review feedback correctly points out that the corresponding TypeScript type definitions (@types/ws) in devDependencies should also be updated to ^8.x.x to prevent potential type mismatch or compilation errors.

Comment thread package.json
@rajat2911
rajat2911 force-pushed the fix/bump-ws-to-8.21.1 branch from f745d10 to 79f56d2 Compare July 27, 2026 01:19
@rajat2911

Copy link
Copy Markdown
Author

Hello @inlined @shettyvarun268 @Berlioz Could you guys please review this PR ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Security: ws dependency pinned to vulnerable ^7.5.10 — please bump to ^8.21.1 (CVE-2026-48779)

2 participants