Medium

@hono/node-server: Unhandled `ECONNRESET` on the socket during an asynchronous WebSocket upgrade crashes the process

  • Disclosed: 12.11.2026
  • Updated: 12.11.2026 23:17

Summary

While @hono/node-server waits for the Hono application to handle a WebSocket upgrade request, the socket has no error listener. If the client resets the TCP connection during that time, the resulting ECONNRESET is emitted as an unhandled 'error' event and the process terminates.

Details

The upgrade handler awaits the application before attaching any listener to the socket. When middleware on the upgrade path does asynchronous work, such as an authentication lookup, a connection reset in that window has no handler. If a global uncaughtException handler swallows the error, the pending upgrade is never released and its entry is retained for the lifetime of the process.

The fix attaches error and close listeners to the socket before calling the application, releases the pending upgrade when the socket closes, and skips the handshake on a destroyed socket.

Impact

An unauthenticated client can terminate the server process with a single connection by sending a WebSocket upgrade request and resetting the connection before the application has responded. Where the crash is suppressed, repeated requests grow the heap.

This affects applications that enable WebSocket support in @hono/node-server and run asynchronous middleware or handlers on the upgrade path.

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
npm package @hono/node-server >= 2.0.0, < 2.1.6 2.1.6

References

CVSS score 5.3/10
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:L
Weakness (CWE)
CWE-248
Platform
npm
Package
@hono/node-server
Disclosed
12.11.2026
Updated
12.11.2026 23:17

Sources and licenses

OSV / GitHub Advisory Database - GHSA-qv5m-9pm6-hqp3 - CC BY 4.0

Vulnerability history: @hono/node-server

All published vulnerabilities of this package (npm package), newest first. Shows whether this is a one-off slip or a package that needs watching.

All (9) in the archive
Total entries
9
First → latest
01.2024 11.2026
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • High 2
  • Medium 7

Disclosures per year

  1. 2024: 2
  2. 2025: 0
  3. 2026: 7
Severity:
  1. @hono/node-server: Unhandled `ECONNRESET` on the socket during an asynchronous WebSocket upgrade crashes the process this entry
    Medium · 5.3 CVE-2026-126343 >= 2.0.0, < 2.1.6 2.1.6

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.