CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-137200

CVE-2026-137200: Denial of Service via Unhandled Upgrade Error in Engine.IO

Alon Barad
Alon Barad
Software Engineer

Dec 1, 2026·10 min read·1 visit

Executive Summary (TL;DR)

Engine.IO prior to 6.6.12 delays attaching an error event listener to incoming upgrade sockets that do not match the configured Engine.IO path. A remote attacker can exploit this timing window by sending an invalid HTTP upgrade request and immediately closing the TCP connection with a RST packet, causing an unhandled exception that crashes the Node.js server.

An uncaught exception vulnerability (CWE-248) in Engine.IO versions prior to 6.6.12 allows remote unauthenticated attackers to cause a Denial of Service (DoS) against Node.js applications utilizing Engine.IO or Socket.IO. By sending an HTTP upgrade request targeting a non-Engine.IO URL path and forcibly resetting the underlying TCP connection before the internal destruction timeout expires, an attacker triggers an unhandled ECONNRESET error event on the socket object, terminating the entire Node.js runtime process.

Vulnerability Overview

Engine.IO serves as the foundational transport engine for the Socket.IO library within the Node.js ecosystem. It manages low-level bidirectional communication between clients and servers, handling the initial HTTP long-polling handshake and the subsequent protocol upgrade to WebSockets. To manage WebSocket transitions, Engine.IO attaches a listener directly to the underlying Node.js HTTP server's upgrade event, inspecting every incoming HTTP upgrade request to determine if it is destined for the Engine.IO path (typically /engine.io/ or /socket.io/).

In deployments where a single Node.js HTTP server hosts multiple web services or secondary WebSocket endpoints alongside Engine.IO, upgrade requests may target URL paths that Engine.IO does not control. To avoid prematurely terminating valid connections meant for other co-hosted upgrade handlers, Engine.IO implements a deferred cleanup mechanism configured via the destroyUpgrade and destroyUpgradeTimeout options. When an unrecognized upgrade request arrives and destroyUpgrade is enabled (the default setting), Engine.IO waits for a specified timeout period (defaulting to 1000 milliseconds) before terminating the unclaimed socket.

CVE-2026-137200 (also tracked as GHSA-v775-f652-7rv6) is an uncaught exception vulnerability (CWE-248) located within this deferred socket termination logic in packages/engine.io/lib/server.ts. In versions of engine.io prior to 6.6.12, the error listener for the raw TCP socket (socket.on("error", ...)) was registered inside the setTimeout() callback rather than synchronously upon receipt of the upgrade event. This architectural flaw creates a race window equal to the duration of destroyUpgradeTimeout during which the socket has no active error handler attached.

Because Node.js treats unhandled error events on EventEmitter instances (including net.Socket) as fatal exceptions, any socket-level network error occurring within this unguarded window propagates directly to the Node.js global event loop as an uncaughtException. An unauthenticated remote attacker can deliberately trigger this condition by transmitting an HTTP upgrade request to a non-Engine.IO path (such as /) and immediately resetting the TCP stream, crashing the host Node.js process and disconnecting all active clients.

Root Cause Analysis

To understand the root cause of CVE-2026-137200, it is necessary to examine how the Node.js http.Server and net.Socket classes interact during an HTTP Connection: Upgrade lifecycle. When an HTTP client requests a protocol upgrade, the Node.js HTTP parser intercepts the headers, stops standard HTTP request-response processing, and emits the upgrade event on the http.Server instance. This event passes three arguments to registered listeners: the http.IncomingMessage request object (req), the underlying net.Socket network stream (socket), and a Buffer containing the first packet of the upgraded stream (head).

Once the http.Server emits the upgrade event, it relinquishes standard HTTP error management over the socket instance, transferring full responsibility for stream lifecycle and error handling to the application-level upgrade listener. In Node.js, net.Socket inherits from EventEmitter. According to the Node.js runtime specification, if an EventEmitter instance emits an error event and no listeners are registered for that specific event type, the runtime formats the error as an unhandled exception, prints the stack trace, and exits the process with a non-zero exit code.

In packages/engine.io/lib/server.ts, the attach() method binds an upgrade event listener to the HTTP server. When this listener receives a request, it first checks whether check(req) matches the configured Engine.IO path. If the path check returns false and the server is configured to destroy unhandled upgrades (options.destroyUpgrade !== false), Engine.IO schedules a timer using setTimeout() to verify if another handler has written data to the socket (socket.bytesWritten <= 0) before calling socket.end().

The vulnerability exists because the developer placed the socket.on("error", ...) registration inside the asynchronous setTimeout closure, assuming that errors would only occur during the execution of socket.end(). However, network sockets operate asynchronously and can experience I/O faults at any point in their lifecycle. When a remote peer transmits a TCP Reset (RST) packet while the timer is still pending, the operating system's network stack signals an abrupt termination to the libuv event loop. Libuv translates this into an ECONNRESET error and emits it on the net.Socket instance before the setTimeout callback executes, hitting the missing listener state.

Code Analysis

The vulnerable logic resides in the attach() method of the Server class within packages/engine.io/lib/server.ts. In versions prior to 6.6.12, when an incoming HTTP upgrade request failed the path validation check, the server scheduled the cleanup callback without protecting the raw socket during the timeout wait period.

// VULNERABLE CODE: packages/engine.io/lib/server.ts (prior to 6.6.12)
if (false !== options.destroyUpgrade) {
  // timeouts are needed to give other upgrade handlers a chance
  // to handle the upgrade
  setTimeout(function () {
    // @ts-ignore
    if (socket.writable && socket.bytesWritten <= 0) {
      // FLAW: Error listener is only registered after destroyUpgradeTimeout expires.
      // Any socket error emitted before this callback fires is completely unhandled.
      socket.on("error", (e) => {
        debug("error while destroying upgrade: %s", e.message);
      });
      return socket.end();
    }
  }, destroyUpgradeTimeout);
}

The patch, introduced in commit f8e8746492f4118c7ef6a40e51f9c26fdc3ecc31, resolves this condition by hoisting the socket.on("error", ...) registration outside of the setTimeout closure. By executing the listener registration synchronously within the upgrade event handler execution tick, the socket is immediately protected against asynchronous network errors.

File: packages/engine.io/lib/server.ts
@@ -1011,12 +1011,13 @@ export class Server extends BaseServer {
           // but by adding a handler, we prevent that
           // and if no eio thing handles the upgrade
           // then the socket needs to die!
+          socket.on("error", (e) => {
+            debug("error while destroying upgrade: %s", e.message);
+          });
+
           setTimeout(function () {
             // @ts-ignore
             if (socket.writable && socket.bytesWritten <= 0) {
-              socket.on("error", (e) => {
-                debug("error while destroying upgrade: %s", e.message);
-              });
               return socket.end();
             }
           }, destroyUpgradeTimeout);

> [!NOTE] > This patch addresses a regression/incomplete fix pattern related to an earlier commit (425e833ab13373edf1dd5a0706f07100db14e3c6 in engine.io@6.2.1), which originally introduced the error listener inside the setTimeout block to catch errors thrown specifically during the socket.end() call.

Evaluating the completeness of the fix in f8e8746492f4118c7ef6a40e51f9c26fdc3ecc31 shows that it effectively closes the timing window for all invalid upgrade paths when destroyUpgrade is enabled. Because Node.js processes the upgrade event and executes all synchronous statements in the listener before polling libuv for subsequent network I/O events (such as a follow-up TCP RST), an attacker cannot win a race between the HTTP upgrade header parse and the error listener attachment. One edge case to consider is when an application explicitly sets destroyUpgrade: false in the Engine.IO server configuration; in that scenario, Engine.IO intentionally ignores non-matching upgrade requests altogether, leaving it up to the application developer or secondary WebSocket server to attach error handlers to those sockets.

Exploitation

Exploiting CVE-2026-137200 requires no authentication, no prior session establishment, and minimal network bandwidth. The only prerequisites are that the target Node.js server utilizes a vulnerable version of engine.io (< 6.6.12), has destroyUpgrade enabled (the default setting), and exposes its HTTP port directly or through a proxy that forwards WebSocket upgrade requests on arbitrary paths.

The attack methodology consists of a two-step TCP sequence:

  1. Establish a standard TCP connection to the target HTTP server port and transmit a raw HTTP/1.1 GET request containing the Connection: Upgrade and Upgrade: websocket headers, specifying a URL path that does not match the Engine.IO endpoint (for example, GET / HTTP/1.1).
  2. Wait briefly (e.g., 10 milliseconds) to allow the server to parse the HTTP headers and enter the setTimeout waiting state, then abruptly tear down the connection by transmitting a TCP RST packet instead of a standard FIN handshake.

The official regression test included in the patch commit (packages/engine.io/test/fixtures/connection-reset.js) demonstrates this exact mechanism using the Node.js node:net library and the socket.resetAndDestroy() method, which forces the OS socket layer to close the connection with a TCP RST packet:

/**
 * Official Reproduction Fixture
 * File: packages/engine.io/test/fixtures/connection-reset.js
 */
const { listen } = require("../common");
const net = require("node:net");
 
const engine = listen((port) => {
  const socket = net.connect(port, () => {
    // Step 1: Send WebSocket upgrade request to a non-Engine.IO path ("/")
    socket.write(
      "GET / HTTP/1.1\r\nConnection: Upgrade\r\nUpgrade: websocket\r\n\r\n",
    );
    // Step 2: Abruptly reset TCP connection before destroyUpgradeTimeout (1000ms) fires
    setTimeout(() => socket.resetAndDestroy(), 10);
  });
});
 
setTimeout(() => {
  engine.httpServer.close();
  engine.close();
}, 200);

When executed against a vulnerable server, the target Node.js process immediately terminates with the following unhandled exception trace:

node:events:495
      throw er; // Unhandled 'error' event
      ^
 
Error: read ECONNRESET
    at TCP.onStreamRead (node:internal/stream_base_commons:217:20)
Emitted 'error' event on Socket instance at:
    at emitErrorNT (node:internal/streams/destroy:151:8)
    at emitErrorCloseNT (node:internal/streams/destroy:116:3)
    at process.processTicksAndRejections (node:internal/process/task_queues:82:21) {
  errno: -104,
  code: 'ECONNRESET',
  syscall: 'read'
}

Impact Assessment

The primary impact of CVE-2026-137200 is a complete Denial of Service (DoS) of the target application, reflected in its CVSS v3.1 base score of 7.5 (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H). Because Node.js utilizes a single-threaded event loop architecture, an uncaught exception brings down the entire OS process rather than just terminating the offending worker thread or request context.

In production deployments, a single maliciously crafted TCP connection and reset packet will drop all concurrent HTTP requests and terminate all active Socket.IO/WebSocket sessions hosted by that Node.js process. If the application relies on in-memory state (such as local session caches, game lobbies, or real-time collaboration rooms), all transient data within that process is immediately lost.

Furthermore, even when production applications are deployed behind process managers (such as PM2, systemd, or Forever) or container orchestrators (such as Kubernetes or Docker Swarm) configured with automatic restart policies, an attacker can achieve sustained downtime. By sending a continuous stream of upgrade-and-reset packets at a rate of one request every few seconds, an attacker can force the container or service into a continuous crash loop (CrashLoopBackOff in Kubernetes), rendering the application permanently unavailable until network-level filtering or patching is applied.

There is no Confidentiality (C:N) or Integrity (I:N) impact associated with this vulnerability, as the flaw strictly involves unguarded stream error emission and does not permit memory corruption, information disclosure, or arbitrary code execution.

Remediation

The definitive remediation for CVE-2026-137200 is to upgrade engine.io to version 6.6.12 or later. Because engine.io is frequently installed as a transitive dependency of socket.io, developers and system administrators must verify the resolved version inside their package lockfiles (package-lock.json, yarn.lock, or pnpm-lock.yaml).

# Update engine.io to the patched release
npm update engine.io
 
# Verify the resolved dependency tree ensures engine.io >= 6.6.12
npm ls engine.io

For environments where immediate package upgrades are not possible, organizations can apply an application-level workaround directly on the Node.js http.Server instance. By attaching a fallback upgrade listener that checks for existing error handlers and binds a no-op listener if none are present, the uncaught exception is prevented:

// Application-level workaround for Engine.IO < 6.6.12
httpServer.on("upgrade", (req, socket, head) => {
  if (socket.listenerCount("error") === 0) {
    socket.on("error", (err) => {
      // Prevent unhandled ECONNRESET from crashing the Node.js process
    });
  }
});

In addition to application-layer fixes, infrastructure teams can mitigate the attack vector at the network perimeter using a reverse proxy (such as NGINX, HAProxy, or Envoy). Because the vulnerability is only triggered when an HTTP upgrade request targets a path not managed by Engine.IO, configuring the reverse proxy to strictly restrict Upgrade: websocket headers to the known Socket.IO endpoint (e.g., /socket.io/) blocks the exploit payload before it reaches the Node.js backend:

# NGINX mitigation: Reject WebSocket upgrades on non-Socket.IO locations
location / {
    if ($http_upgrade ~* "websocket") {
        return 400;
    }
    proxy_pass http://nodejs_backend;
}
 
location /socket.io/ {
    proxy_pass http://nodejs_backend;
    proxy_http_version 1.1;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection "Upgrade";
    proxy_set_header Host $host;
}

Official Patches

Socket.IOGitHub Security Advisory GHSA-v775-f652-7rv6
Socket.IOFix Commit in socketio/socket.io
Socket.IOEngine.IO 6.6.12 Release Notes

Fix Analysis (1)

Technical Appendix

CVSS Score
7.5/ 10
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Affected Systems

engine.iosocket.io

Affected Versions Detail

Product
Affected Versions
Fixed Version
engine.io
socketio
< 6.6.126.6.12
AttributeDetail
CVE IDCVE-2026-137200 (GHSA-v775-f652-7rv6)
Vulnerability ClassCWE-248: Uncaught Exception
CVSS v3.1 Score7.5 High (CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H)
Attack VectorNetwork / Unauthenticated HTTP Upgrade + TCP RST
Affected Componentengine.io (< 6.6.12)
Patched Versionengine.io@6.6.12
ImpactRemote Denial of Service (Node.js Process Crash)
Exploit StatusProof-of-Concept Available (Official Test Fixture)

MITRE ATT&CK Mapping

T1499Endpoint Denial of Service
Impact
T1499.004Application or System Exploitation
Impact
CWE-248
Uncaught Exception

An exception is thrown from a function, penalty, or operation, and it is not caught by any error handler, leading to abrupt termination of the program execution.

Known Exploits & Detection

GitHub (Official Regression Test / PoC)Official reproduction fixture (packages/engine.io/test/fixtures/connection-reset.js) demonstrating the unhandled ECONNRESET crash via socket.resetAndDestroy().

Vulnerability Timeline

Fix committed to socketio/socket.io repository (f8e8746492f4118c7ef6a40e51f9c26fdc3ecc31)
2026-11-16
GitHub Security Advisory GHSA-v775-f652-7rv6 and CVE-2026-137200 published
2026-11-30
NVD publishes official CVE record with CVSS v3.1 score of 7.5
2026-11-30

References & Sources

  • [1]GitHub Security Advisory: GHSA-v775-f652-7rv6
  • [2]Fix Commit: catch errors when destroying invalid upgrades
  • [3]Engine.IO 6.6.12 Release
  • [4]NVD Vulnerability Detail: CVE-2026-137200
  • [5]CVE.org Record: CVE-2026-137200
  • [6]CVEProject cvelistV5 Record: CVE-2026-137200
  • [7]CWE-248: Uncaught Exception

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•about 1 hour ago•CVE-2026-137199
9.2

CVE-2026-137199: OS Command Injection in cross-spawn on Windows via Batch File Argument Escaping Bypass

CVE-2026-137199 (GHSA-ghv9-86vm-4v8m) is a critical OS command injection vulnerability in the Node.js cross-spawn library affecting versions prior to 6.0.7 and 7.1.0 on Windows. The vulnerability stems from incomplete metacharacter escaping when routing batch scripts (.bat and .cmd) outside of node_modules/.bin through cmd.exe, alongside flaws in file extension canonicalization, environment variable expansion, and line break handling. Attackers who control arguments passed to batch scripts can break out of argument quoting and execute arbitrary system commands.

Alon Barad
Alon Barad
4 views•15 min read
•about 2 hours ago•GHSA-CX3C-RMCX-FF35
5.9

GHSA-cx3c-rmcx-ff35: Metadata Partition-Key Collisions in OpenTelemetry Collector exporterhelper

An improper data encoding vulnerability (CWE-172) exists in the OpenTelemetry Collector exporterhelper package between versions 0.147.0 and 0.163.x. When metadata-partitioned batching is enabled with multiple metadata keys, the partition key generator uses an unescaped null byte delimiter to concatenate key names and multi-valued header arrays. An authenticated attacker capable of sending multi-valued HTTP or gRPC headers to an ingress receiver can induce partition key collisions, causing cross-tenant telemetry data mixture, data poisoning, or unauthorized data exfiltration.

Alon Barad
Alon Barad
6 views•10 min read
•about 3 hours ago•CVE-2026-137187
5.4

CVE-2026-137187: Fail-Open Project Allowlist Authorization Bypass in @zereight/mcp-gitlab

CVE-2026-137187 (GHSA-5xhm-p3jx-2fmc) is a missing authorization vulnerability (CWE-862) in @zereight/mcp-gitlab affecting versions 2.2.5 through 2.3.6. The flaw exists within the gitlab_api_request tool, where project allowlist enforcement fails open when evaluating API paths that do not conform to the /projects/:id pattern or when following HTTP redirects to an empty relative path. Attackers or compromised LLM agents with access to the api toolset can bypass project isolation boundaries to query or modify group, user, and instance-level GitLab resources permitted by the server's underlying authentication token.

Alon Barad
Alon Barad
6 views•10 min read
•about 5 hours ago•GHSA-R73Q-GWX2-FPXM
6.8

GHSA-r73q-gwx2-fpxm: Arbitrary Host Directory Mount and Sandbox Bypass via Theme Module Replacements in Hugo

Hugo versions 0.152.0 through 0.167.x contain a path traversal and sandbox bypass vulnerability in the module configuration loader. When a root project does not define module replacements, Hugo permits imported themes or modules to define their own module.replacements directives. Because replaced module imports are internally marked as project-replaced, they bypass theme directory path restrictions, allowing an untrusted theme to mount arbitrary host filesystem directories and expand the Node.js read sandbox.

Amit Schendel
Amit Schendel
8 views•10 min read
•about 6 hours ago•CVE-2026-135388
9.1

CVE-2026-135388: Cryptographic Signature Verification Bypass in Pion DTLS

CVE-2026-135388 (GHSA-7c2r-jhm9-43vf) is an improper verification of cryptographic signature vulnerability (CWE-347) in Pion DTLS, a pure Go implementation of Datagram Transport Layer Security (RFC 6347). The vulnerability stems from signature scheme confusion and missing cryptographic parameter binding in the handshake verification functions verifyKeySignature and verifyCertificateVerify. By presenting a genuine peer certificate paired with an incompatible or digest-less signature hash algorithm on the wire, an unauthenticated network adversary can bypass signature verification without possessing the peer's private key. This allows peer impersonation and full compromise of confidentiality and integrity in DTLS-protected channels, including WebRTC sessions utilizing SDP certificate fingerprint verification.

Alon Barad
Alon Barad
9 views•10 min read
•about 7 hours ago•CVE-2026-134024
6.8

CVE-2026-134024: Latent Server-Side Request Forgery Gadget in TastyIgniter Media Attachment Handler

CVE-2026-134024 is a Server-Side Request Forgery (SSRF) vulnerability (CWE-918) in the TastyIgniter open-source restaurant management platform prior to version 4.4.4. The flaw resides in the Media::addFromUrl() helper method within the tastyigniter/core package, which initiates outbound HTTP GET requests to caller-supplied URLs and persists the response body without validating the URI scheme, target hostname, or resolved IP address. Although unreachable in a default unextended installation, the method functions as a latent SSRF gadget that exposes the host environment to internal network reconnaissance and cloud metadata extraction when invoked by third-party extensions or custom application code.

Alon Barad
Alon Barad
8 views•10 min read