From f4d182e4ee7e77e8b24c876be720cd562271400b Mon Sep 17 00:00:00 2001
From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com>
Date: Wed, 24 Jul 2024 16:43:52 +0800
Subject: [PATCH] build(deps-dev): bump ws from 8.17.0 to 8.18.0 in /web
(#1668)
Bumps [ws](https://github.com/websockets/ws) from 8.17.0 to 8.18.0.
Sourced from ws's
releases. A request with a number of headers exceeding
the[ const wss = new WebSocket.Server({ port: 0 }, function () {
const chars =
"!#$%&'*+-.0123456789abcdefghijklmnopqrstuvwxyz^_`|~".split('');
const headers = {};
let count = 0; for (let i = 0; i < chars.length; i++) {
if (count === 2000) break; } headers.Connection = 'Upgrade';
headers.Upgrade = 'websocket';
headers['Sec-WebSocket-Key'] = 'dGhlIHNhbXBsZSBub25jZQ==';
headers['Sec-WebSocket-Version'] = '13'; const request = http.request({
headers: headers,
host: '127.0.0.1',
port: wss.address().port
}); request.end();
});
Release notes
8.18.0
Features
Blob
(#2229).8.17.1
Bug fixes
server.maxHeadersCount
][]
threshold could be used to crash a ws server.const http = require('http');
const WebSocket = require('ws');
for (let j = 0; j < chars.length; j++) {
const key = chars[i] + chars[j];
headers[key] = 'x';
if (++count === 2000) break;
}
The vulnerability was reported by Ryan LaPointe in websockets/ws#2230.
... (truncated)
976c53c
[dist] 8.18.059b9629
[feature] Add support for Blob
(#2229)0d1b5e6
[security] Use more descriptive text for 2017 vulnerability link15f11a0
[security] Add new DoS vulnerability to SECURITY.md3c56601
[dist] 8.17.1e55e510
[security] Fix crash when the Upgrade header cannot be read (#2231)6a00029
[test] Increase code coverageddfe4a8
[perf] Reduce the amount of crypto.randomFillSync()
calls