Node2Shell (CVE-2026-111497): Exploit Scope, Detection and Mitigation

· Original article ↗

Summary

Node2Shell is an out-of-bounds write in Brotli that affects Node.js services decoding attacker-controlled data. Code execution was demonstrated in a limited setup; patching, reducing exposure and monitoring post-exploitation behavior are advised.

Key points

  • The flaw occurs when Brotli’s decoder ignores an error after a malformed stream requests a block-type switch, allowing a write past the buffer.
  • Fixed Node.js releases are 22.23.4, 24.22.1 and 26.12.1. Node.js 20 and older have no fix; distributions using system Brotli need separate package checks.
  • Exposure depends on whether an application or library decompresses attacker-controlled Brotli data. Examples include Express 5’s default JSON parsing, server-side fetch responses and direct zlib use.
  • As of October 23, no confirmed in-the-wild exploitation was reported. Public proof-of-concept code appeared quickly after the fixes.
  • Researchers readily reproduced crashes; reliable remote code execution had been reproduced in one setup. Imperva demonstrated code execution on the official Node.js 24.22.0 Linux arm64 image, requiring several attempts.
  • The article recommends patching, auditing Brotli decoding paths, limiting untrusted compressed input, running services with least privilege and monitoring for suspicious process activity.

Article Details

Vulnerability Types
  • Out-of-bounds write
  • Unchecked return value
  • Buffer overflow
Severity
Critical (CVSS v4.0 9.2); the Node.js advisory rates it high
Affected Versions
  • Node.js 22.x versions before 22.23.4
  • Node.js 24.x versions before 24.22.1
  • Node.js 26.x versions before 26.12.1
  • Node.js 25.x (no fix)
  • Node.js 20.x and older (no fix)
  • Brotli 1.0.3 through 1.2.0
  • Bun 1.4.3 and earlier
Exploitation Status
reported
Exploit Availability
public_poc
Patch Status
partial
Workarounds
  • Disable request decompression where possible; in body-parser, set express.json({ inflate: false }).
  • Reject Content-Encoding: br on request bodies at the proxy or load balancer where clients do not send it.
  • Use WAF rules to limit untrusted Brotli traffic on affected paths; this is a mitigation layer, not a fix.

MITRE ATT&CK

CVE

Vendors

Products

Related Articles