Node2Shell, and Why Node.js Users Should Clear Their Diary for 11 November

By Zachary, Hawthorn Security

While most of the web was busy patching PHP2Shell on 21 October, Node.js quietly shipped its own critical fixes the same afternoon. And there's another round coming next week.

If you run anything on Node.js (an API, a Next.js or Nuxt site, a background worker, or even just your build pipeline), here's what you need to know.


What happened on 21 October

Node.js released security updates for all three supported versions: 22.23.4, 24.22.1 and 26.12.1. They fixed ten vulnerabilities, four of them rated high.

The headline bug is CVE-2026-111497, now nicknamed Node2Shell. It's a flaw in the Brotli decompression code that ships inside Node.js. Feed it a specially crafted compressed payload and it can write past the end of a memory buffer. At best that crashes your app. At worst it lets an attacker run their own code on your server.

Within a day, a public proof of concept was out, and researchers reported getting code execution against the official, unmodified Node.js 24 Docker image. It didn't work every time, but it worked.

The same flaw affects Bun before version 1.4.4, and other software that bundles its own copy of Brotli may need updating too.

Are you exposed?

The bug triggers when Node.js decompresses Brotli data an attacker can control. That happens more often than you'd think:

If you're not sure whether any of that applies to you, assume it does until you've checked.

The versions that won't get a fix

This is the bit that catches people out. Node.js 20 reached end of life on 30 April 2026, along with 23 and 25 before it. None of them got the Node2Shell fix, and none of them will get next week's fixes either.

Node.js 20 was hugely popular, and plenty of servers, Docker images and CI pipelines are still pinned to it. If that's you, you're not “a bit behind”. You're running a version with a public remote code execution exploit and no patch.

And now, round two: 11 November

On 3 November, the Node.js project announced another security release, due on or shortly after Wednesday 11 November. It covers Node.js 22, 24 and 26, and the most serious issue is rated HIGH.

There are no details yet. That's normal: the Node.js team holds back the specifics until the fix is out so attackers don't get a head start. But after the last few weeks, it would be optimistic to assume nobody will be looking for these bugs the moment they're published.

The good news is you've had a week's warning. Use it.

The usual traps

Updating Node.js sounds simple. In practice, it's where things get missed:

What to do this week

  1. Find every Node.js install. Servers, containers, CI runners, build boxes and laptops. Run node --version everywhere, including inside your images.
  2. Make sure the 21 October fixes are in. You want 22.23.4, 24.22.1 or 26.12.1 or newer.
  3. Get off Node.js 20 and older. For most people, Node.js 24 is the best target. Node.js 22 is only supported until April 2027.
  4. Avoid pinning exact versions unless you have a process to bump them. Pinned tags are great for reproducible builds and terrible if nobody updates them.
  5. Book a patching window for 11 and 12 November. Plan to update, rebuild and redeploy as soon as the release lands.
  6. As a stopgap, block Brotli-encoded requests (Content-Encoding: br) at your reverse proxy or load balancer. It reduces your exposure on incoming requests, but it doesn't protect outgoing fetch() calls, so it's a bridge, not a fix.

Not sure what you're running?

Between PHP2Shell, Node2Shell and next week's release, October and November have been a rough couple of months for anyone running their own servers. The businesses that came through it fine all had one thing in common: they knew exactly what they were running and had a process to update it.

That's what a Hawthorn Security review gives you. I'll go through your servers, containers and deployment pipelines, find the outdated and unsupported runtimes, and give you a clear, prioritised list of what to fix first. No jargon and no scare tactics, just a plain answer to “are we OK?”

If you'd rather not spend next Wednesday wondering, now's a good time to get in touch.

Book a security review at hawthornsecurity.uk


Sources