Skip to content
RCE Write-up Advanced

A Critical RCE in React Server Components

React Server Components contained an unsafe deserialisation flaw in the Flight protocol that let an attacker send a crafted HTTP request and run arbitrary JavaScript on the server. Because the vulnerable endpoint was present in default configurations, a standard Next.js app could be exploited without any code changes.

medium.com

Published on medium.com

On December 3, 2025, the React team disclosed one of the most severe vulnerabilities in the framework’s history: CVE-2025–55182, better known as React2Shell. With a maximum CVSS score of 10.0, this critical remote code execution vulnerability has sent shockwaves through the development community.

Nabil Mouzouna نبيل مزونة, on medium.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the Flight protocol deserialiser in the react-server package processed attacker-controlled payloads without properly validating their structure, allowing self-referencing gadget chains to reach code execution.

Impact

An unauthenticated attacker could execute arbitrary code on the server and then read files, reach cloud metadata, steal credentials or install backdoors; the text notes that Vercel deployed WAF rules as temporary protection but says upgrading is still essential.

What the attacker needed

No authentication; No user interaction; Vulnerable React/Next.js version; Network access to the server

The fix

It was fixed by upgrading React to 19.0.1, 19.1.2 or 19.2.1 and Next.js to 14.2.35 or 15.1.4 depending on the version in use.

How it was found

  1. Craft a specially formatted HTTP POST request containing a malicious payload.
  2. Send it to the vulnerable React Server Components endpoint.
  3. The server deserialises the payload without proper validation.
  4. Self-referencing gadget chains lead to arbitrary JavaScript execution on the server.
  5. Use the code execution to read files, access cloud metadata, steal credentials or install backdoors.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

When a server receives data from a client, it has to turn that data back into program objects, a process called deserialisation. If the server trusts the shape of that data too much, an attacker can craft input that makes the server run their own code. Here that meant anyone who could send a web request could take over the server.

What is RCE?

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.

Similar reports

View all

Same bug class and techniques, clearest first.

Remote code execution

The lesson behind this report.

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.