Security

React2Shell

Here’s a quick one, while the patches are fresh.

On 3 December the React team disclosed CVE-2025-55182, nicknamed React2Shell. It’s a CVSS 10.0, unauthenticated remote code execution vulnerability in React Server Components (RSC), caused by unsafe deserialisation in the protocol RSC uses to talk to the server. A single crafted HTTP request can run code on the server. Next.js was affected through its App Router and tracked the issue separately at first.

Working proof-of-concept code was public by 4 December, and on 5 December CISA added the CVE to its Known Exploited Vulnerabilities catalogue. Several security firms are reporting exploitation by multiple groups, including China-linked actors.

Am I Affected?

You may be affected if you run server-side React with React Server Components. That includes frameworks built on RSC, such as Next.js App Router applications. The affected packages are react-server-dom-webpack, react-server-dom-parcel and react-server-dom-turbopack at versions 19.0.0, 19.1.0, 19.1.1 and 19.2.0. Purely client-side React apps aren’t affected.

Check with something like npm ls react-server-dom-webpack, or your software composition analysis tool.

What To Do

  1. Upgrade React and Next.js to the fixed versions in the official advisories, then rebuild and redeploy. Updating the lock file isn’t the same as fixing production.
  2. Use WAF rules as a stopgap, not a fix. The major CDNs and cloud WAFs have published rules, but rules get bypassed.
  3. Hunt for unexpected processes started by your Node.js servers, and for unusual POST requests to RSC endpoints since 3 December.
  4. Rotate secrets that could be reached from compromised servers, such as environment variables and cloud credentials.

It reminds me of December 2021 and Log4Shell: a ubiquitous library, a trivially exploitable bug, and a holiday season ahead. Patch now, so you can enjoy the mince pies later. ๐Ÿ™‚

More Information