
pfSense CE 2.9.0-DEVELOPMENT - Media - Remoto - Open redirect - HTTP 301 $http_host
abraxaslabs.tech · github.com/abraxas · @abraxas_null · [email protected] · pfsense-https-host-redirect
Classe: Open redirect Portata: Remota
pfSense CE 2.9.0-DEVELOPMENT (9363ac5) - pfsense.org
system.inc emette un server{} sulla porta 80 con return 301 https://$http_host$redirectport$request_uri; e senza server_name. nginx restituisce 301 prima di php-fpm, quindi il DNS-rebind di auth.inc non viene mai eseguito.
| ID | nessuna CVE al momento |
| Classe | Open redirect |
| Portata | Remota (WebGUI autenticata salvo diversa indicazione) |
| CWE | CWE-601 |
| CVSS | Media: 4.7 CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:L/I:N/A:N |
| Prodotto | pfSense CE |
| Affetto | 2.9.0-DEVELOPMENT (9363ac5b8651a1c7a333180425ce7719070f95f9) |
| Auth | Sessione WebGUI con unauth client that can hit the WebGUI HTTP listener |
| Licenza | GNU Affero GPL v3.0 |
| Lab | solo 127.0.0.1 |
Ho fissato il master pubblico 9363ac5. Il lab è un gadget PHP del sink fissato, HTTP su loopback su 127.0.0.1:19210.
Write-up della serie: https://abraxaslabs.tech/research/pfsense-ce-leftovers
| Metodo | Sink | Privilegio |
|---|---|---|
| GET / non autenticato su TCP/80 con un Host ostile | nginx return 301 https://$http_host... | Integrità: Nessuna. |
| stesso residuo | stesso sink | Ricognizione: Provato in laboratorio: Host evil.example è diventato Location https://evil.example/index.php. Il DNS-rebind PHP 501 non viene eseguito su questo 301. |
| stesso residuo | stesso sink | Disponibilità: Nessuna dimostrata. |
Richiede: unauth client that can hit the WebGUI HTTP listener. CSRF-magic su POST salvo diversa indicazione. WebGUI PHP-FPM è root.
Richiede: unauth client that can hit the WebGUI HTTP listener. CSRF-magic su POST salvo diversa indicazione. WebGUI PHP-FPM è root. CSRF-magic su POST salvo diversa indicazione. WebGUI PHP-FPM è root.
DNS-rebind PHP sulla GUI HTTPS stessa.
Nessun Diagnostics: Command a meno che anche quella pagina sia concessa.
cd lab
./run.sh
Loopback 127.0.0.1:19210. Progetto Compose pfsense-https-host-redirect. Witness PFSENSE-HTTPS-HOST-REDIRECT-WITNESS. Solo loopback: 127.0.0.1:19210. Progetto Compose pfsense-https-host-redirect. Witness PFSENSE-HTTPS-HOST-REDIRECT-WITNESS. Gadget PHP delle righe fissate. Lo stack viene smontato dopo l'esecuzione.
Ultima riga:
SUCCESS PFSENSE-HTTPS-HOST-REDIRECT control-localhost=yes trigger-evil=yes php-rebind-skips-301=yes PFSENSE-HTTPS-HOST-REDIRECT-WITNESS
Usare un hostname configurato, oppure $host (in allowlist), non $http_host.
9363ac5b8651a1c7a333180425ce7719070f95f9