Repository navigation
fix: Bump ws from 8.21.0 to 8.21.3 - #3119
Conversation
|
🚀 Thanks for opening this pull request! We appreciate your effort in improving the project. Please let us know once your pull request is ready for review. Tip
Note Please respond to review comments from AI agents just like you would to comments from a human reviewer. Let the reviewer resolve their own comments, unless they have reviewed and accepted your commit, or agreed with your explanation for why the feedback was incorrect. Caution Pull requests must be written using an AI agent with human supervision. Pull requests written entirely by a human will likely be rejected, because of lower code quality, higher review effort and the higher risk of introducing bugs. Please note that AI review comments on this pull request alone do not satisfy this requirement. Our CI and AI review are safeguards, not development tools. If many issues are flagged, rethink your development approach. Invest more effort in planning and design rather than using review cycles to fix low-quality code. |
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Essentials Run ID: 📒 Files selected for processing (2)
Included review availability: Your plan provides up to 5 included reviews per hour; 3 remain after this review. 📝 WalkthroughWalkthroughThe Changesws dependency update
Estimated code review effort: 1 (Trivial) | ~5 minutes Suggested reviewers: Merge Risk: ⚪ Minimal · up to The dependency update is ready to merge after normal checks; no actionable compatibility issue is established. 🚥 Pre-merge checks | ✅ 7✅ Passed checks (7 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## alpha #3119 +/- ##
=======================================
Coverage 99.98% 99.98%
=======================================
Files 64 64
Lines 6339 6339
Branches 1538 1526 -12
=======================================
Hits 6338 6338
Misses 1 1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
## [8.6.2-alpha.1](8.6.1...8.6.2-alpha.1) (2026-09-23) ### Bug Fixes * Bump ws from 8.21.0 to 8.21.3 ([#3119](#3119)) ([efed232](efed232))
|
🎉 This change has been released in version 8.6.2-alpha.1 |
## [8.6.2](8.6.1...8.6.2) (2026-09-23) ### Bug Fixes * Bump ws from 8.21.0 to 8.21.3 ([#3119](#3119)) ([efed232](efed232))
|
🎉 This change has been released in version 8.6.2 |
Pull Request
Issue
wsbefore 8.21.1 is vulnerable to memory exhaustion via incomplete fragmented messages: GHSA-73jw-fp74-p77x / CVE-2026-62389 (HIGH), reported in websockets/ws#2331. The fix for GHSA-96hv-2xvq-fx4p inws8.21.0 added themaxFragmentsandmaxBufferedChunkslimits, but their defaults were high enough that a peer could send a text frame withFIN=0followed by many tiny continuation frames, never finish the message, and pin a lot of heap memory.ws8.21.1 fixes this.wsis a direct production dependency of the SDK. The Node.js build uses it as the WebSocket implementation for the LiveQuery client (src/WebSocketController.ts). The GitHub Advisory Database lists this advisory as unreviewed, with no structured affected version ranges, so Dependabot has raised neither an alert nor a PR for it.Approach
Bump
wsfrom 8.21.0 to 8.21.3, the latest release, with an exact pin as before. Onlypackage.jsonandpackage-lock.jsonchange: the rootwsentry, and itsversion,resolvedandintegrityfields in the lock file. No other packages were re-resolved.ws8.21.3 declaresengines.node>=10.0.0, which is within this repository'sengines.noderange.The SDK creates the socket with
new WebSocket(serverURL)and no options, so the newwsdefaults apply. They have no practical effect on LiveQuery traffic:ws.send(), which produces a single unfragmented frame. That is far below the newmaxFragmentsdefault of 16384.maxBufferedChunkscounts socket reads buffered while a frame is incomplete. At the new default of 262144, a limit is only reached for payloads far above the 100 MiBmaxPayloaddefault.As a local check, a
ws8.21.3 client with default options received a 20 MiB single-frame message without error. The LiveQuery client path is already covered end to end byintegration/test/ParseLiveQueryTest.js, which runs the Node.js build against a real Parse Server LiveQuery server in CI on every Node.js version in the matrix. So no new tests were added.Changes
maxFragmentslimit (websockets/ws@a2f4e7c, fix: count empty continuation frames toward the maxFragments limit websockets/ws#2329). The default values ofmaxBufferedChunks(1048576 → 262144) andmaxFragments(131072 → 16384) were lowered (websockets/ws@f197ac6, Default maxFragments still allows memory-exhaustion DoS (incomplete GHSA-96hv-2xvq-fx4p fix) websockets/ws#2331, [fix] Fixing Default maxFragments still allows memory exhaustion Dos websockets/ws#2332). This fixes GHSA-73jw-fp74-p77x / CVE-2026-62389.wsserver now correctly rejects permessage-deflate offers whoseclient_max_window_bitsis smaller than its configuredclientMaxWindowBits(websockets/ws@e97a20e). This is server-side only and does not affect the SDK, which useswsonly as a client.Full diff: websockets/ws@8.21.0...8.21.3
Breaking Changes
None. The lower
maxFragmentsandmaxBufferedChunksdefaults are the security fix itself. Normal LiveQuery server messages stay far below them.Code Changes Required
None. The upgrade is a drop-in replacement.
Tasks
No tasks apply. Existing LiveQuery integration tests already cover the
wsclient path, and no documentation changes are needed.Summary by CodeRabbit