Brotli decoder flaw affects Node.js, Bun, Python and Envoy
A memory corruption bug in Google's Brotli decoder can crash software or let attackers run code in several runtimes and proxies. The Hacker News reports fixes exist; update and restart services.
A memory-corruption bug in Google's Brotli decoder can let crafted compressed data overwrite memory and potentially crash a program or run attacker-controlled code. The Hacker News reports the flaw, tracked as CVE-2026-111497, appears in many programs that include Google’s C Brotli decoder, including Node.js, Bun, Python packages, and Envoy when they decode Brotli compressed input.
What the report found
According to The Hacker News, the bug allows a specially crafted Brotli stream to write past the end of a buffer and corrupt program memory. The issue lives in the C code that unpacks a Brotli stream, so any piece of software that ships its own copy of that decoder can inherit the vulnerability.
The Hacker News lists affected software and fixed releases, for example fixed Node.js builds and fixed Bun and Python package releases. The article says Google and Node.js shipped fixes on October 21, and other projects have followed with their own updates. The story notes the fix was added to the Brotli source code in February but did not appear in a Brotli release until October 21.
Imperva researchers demonstrated that attacker-supplied code could run on an unpatched Node.js 24.22.0 build for Linux on ARM64. Imperva’s Red Team called that work "Node2Shell," and the exploit reportedly required several attempts, has not been released, and was not tested on other builds. OpenAI’s Codex Security team reported the flaw and described a two-way risk: an unpatched server that accepts compressed input could be taken over by a malicious client, and an unpatched client that accepts compressed input could be taken over by a malicious server.
Federal and vendor assessments cited in the article show no confirmed in-the-wild exploitation so far. The Cybersecurity and Infrastructure Security Agency recorded exploitation as "none" and automation as "no," and Red Hat said there is no reliable public proof-of-concept for running code. Severity ratings cited in the report vary: Google gave the CVE a 9.2 rating on CVSS 4.0, Node.js calls it high, and Red Hat rates it 8.1.
Who is exposed and when
A program is only exposed if it decodes Brotli data that an attacker can control. The Hacker News explains common exposure paths:
- Node.js and Bun, when their built-in fetch() reads a response sent with Content-Encoding: br, or when code such as Express and body-parser unpacks a Brotli request body. A plain Node HTTP server that does not decode request bodies is not exposed unless other middleware is involved.
- Envoy and Istio are affected only when Brotli decompression is enabled, for example by an Envoy filter; where decompression is off, the bug cannot be reached.
- In Python, the presence of the Brotli or brotlicffi package is itself a risk because popular HTTP clients will decode Brotli responses automatically, so an app can be exposed without importing Brotli directly.
The Hacker News also points out that web application firewalls provide limited protection. Vercel added WAF rules on disclosure day but said those rules do not protect responses fetched by serverless functions from other servers. For that path, updating the runtime or library is the only full fix.
What to do now: practical steps
Follow these actions in order, as reported by The Hacker News:
- Update affected runtimes and libraries to the fixed releases listed by vendors, then restart the service and rebuild any container images, because a running process keeps the old decoder until it restarts.
- If you cannot update immediately, stop decoding untrusted Brotli data: reject incoming requests that include Content-Encoding: br before any proxy or parser decodes the body.
- Turn off automatic Brotli decoding in HTTP clients and reject Brotli responses before they are decoded.
- In Python, uninstall the Brotli and brotlicffi packages so HTTP clients fall back to gzip and deflate.
- Note that for Node.js, The Hacker News reports no published workaround, making runtime updates the only practical fix on that platform.
If you need a quick external check for your site or service, start with a free external scan on our security page: /security.html.
How to prioritize patches and testing
- Prioritize hosts and services that accept or fetch compressed input from external parties, such as APIs, proxy chains, and serverless functions that make outbound requests.
- Treat services that enable Brotli decompression in proxies as higher risk, since the decoder only needs to be enabled to be reachable.
- When testing updates, confirm that the service process and any containers have been restarted and that the updated library version is in use. The Hacker News warns that updates alone are not enough if the old process is still running.
- Watch for vendor advisories and OS package updates. The article notes system packages and distribution fixes are being rolled out at varying times, so check the specific packages you run rather than relying only on dependency scanners.
Bottom line for small teams
The Brotli decoder flaw can be serious where untrusted compressed data reaches your runtime or proxy. The Hacker News reports fixes are available for multiple products, and the safest path is to apply vendor updates and restart services. If you cannot update immediately, block Brotli decoding from untrusted sources, remove Brotli packages where practical, and focus on places that accept or fetch compressed input from others. For a quick external check of how exposed your site is, try our free scan at /security.html.
Sources
- Brotli Decoder Flaw Behind Node.js RCE Also Affects Bun, Python and Other Widely Used Software The Hacker News
This post was drafted with AI from the reporting linked above and published by Jones Web Designs. For full details, read the original sources.