React2Keys makes forgotten React2Shell exposure an expensive mistake

Tags:

Nearly a year after the disclosure of the critical React2Shell vulnerability, attackers are still abusing exposed Next.js servers in large-scale credential harvesting operations.

A campaign dubbed React2Keys has stolen more than 50,000 credentials spanning AI services, cloud infrastructure, databases, payment platforms and cryptocurrency services, according to CloudSEK.

The campaign exploits CVE-2025-55182, a critical unauthenticated remote code execution vulnerability affecting React Server Components and frameworks such as Next.js. CloudSEK said the operation compromised infrastructure associated with more than 400 organizations, with its investigation uncovering over 19,000 affected hosts and victims worldwide.

“React2Keys isn’t just plausible, it happened,” said Crystal Morin, senior cybersecurity strategist at Sysdig. “CloudSEK recovered the attacker’s exfiltration logs, so the 400+ figure is the count from the operator’s records.”

The campaign’s mechanics also explain how attackers could reach such a large number of exposed deployments, Morin added.

Attackers identified, tested, and ranked credentials, with some compromised cloud resources also used to finance further scanning, CloudSEK said in a blog post.

Lingering exposure identified through automated discovery

The campaign reportedly used an automated discovery pipeline that monitored six public Certificate Transparency logs every three minutes. These logs recorded newly issued TLS certificates, allowing the attacker to identify newly deployed domains and add them to its scanning queue almost immediately, the researchers said.

The deployments were then fingerprinted to identify Next.js applications, probing those potentially vulnerable. CloudSEK found that the exploit could be delivered through a single unauthenticated HTTP POST request to a route accessible through Next.js Server Actions. A crafted React Flight payload triggers prototype pollution, allowing arbitrary JavaScript execution within the server’s Node.js process.

“React2Keys’ impact is comparable to that of Shai-Hulud, the self-replicating npm worm that infected hundreds of packages in its first wave in 2025 and leaked credentials from over 25,000 GitHub repositories in its second,” Morin said. “React2Keys doesn’t self-propagate — it’s an operator-run scanning campaign — but both threats are big, automated, and fueled by stolen secrets.”

The vulnerability, disclosed in December 2025, carries critical severity as its exploitation does not require an authenticated session, making internet-facing deployments particularly vulnerable. The React and Next.js maintainers released patches shortly after disclosure, but the React2Keys findings reveal systems remaining exposed.

CloudSEK also found that the attacker could work around certain defensive configurations. When a payload was blocked at the Cloudflare edge, a dedicated module attempted to identify the underlying origin server and target it directly.

Stolen Cloud and AI secrets ranked by value

Once inside a vulnerable application, the attacker searched environment variables, configuration files and other locations for credentials. These include AWS, Azure and Google Cloud identities, database logins, SSH keys, payment tokens, cryptocurrency credentials and API keys belonging to AI providers such as OpenAI, Anthropic and Google.

CloudSEK said the attacker validated and ranked credentials according to their potential monetary value, distinguishing usable keys from expired, disabled, rate-limited or credit-exhausted ones. Some credits were tested against live services to establish whether they can provide access to working AI models or cloud resources.

Randolph Barr, chief information security officer at Cequence Security, said the inclusion of AI keys alongside cloud and payment credentials reflects how attackers are adapting their harvesting operations to the value of modern application environments.

“If someone steals your AI key, they run their work on your bill, and you only find out when the invoice shows up,” Barr said.

Patching won’t evict attackers already inside

React2Keys also introduces a persistence problem for organizations that treat vulnerability remediation as the end of incident response. CloudSEK found the attacker planting its own SSH public key in compromised accounts’ authorized_key files, potentially preserving access even after the vulnerable application is patched.

“What worries me is what the attackers walk away with. They’re grabbing environment variables, cloud keys, database logins, and AI keys, and those keep working even after the app gets patched,” Barr said. “You also must rotate everything that was sitting on that server and check for anything they left behind, like SSH keys you don’t recognize.”

The researchers also identified the reuse of stolen cloud credentials to fund additional scanning infrastructure, including AWS Lambda workers and virtual machines. In effect, compromised organizations can become part of the attacker’s operational infrastructure, with their own cloud resources helping discover further targets.

“If I were a defender, I’d patch fast, keep secrets out of environment variables where I can, use short-lived credentials, lock down cloud roles, and set hard spend limits and alerts on AI usage so a stolen key can’t run up an open tab,” Barr added.

Categories

No Responses

Leave a Reply

Your email address will not be published. Required fields are marked *