This exploits a command execution vulnerability in Pi-Hole <= 3.3. When adding a new domain to the whitelist, it is possible to chain a command to the domain that is run on the OS.
Exploit database
Vulnerability
CVE-2025-34087
Pi-Hole AdminLTE Whitelist (now 'Web Allowlist') Remote Command Execution
Vulnerability details
- Score
- 9.0
- Severity
- critical
CVSS 4.0 · VulnCheck
Vector string
CVSS:4.0/AV:N/AC:L/AT:P/PR:L/UI:N/VC:H/VI:H/VA:H/SC:H/SI:H/SA:HDescription
An authenticated command injection vulnerability exists in Pi-hole versions up to 3.3. When adding a domain to the allowlist via the web interface, the domain parameter is not properly sanitized, allowing an attacker to append OS commands to the domain string. These commands are executed on the underlying operating system with the privileges of the Pi-hole service user. This behavior was present in the legacy AdminLTE interface and has since been patched in later versions.
CVE ProgramExploit source choices
1 sourcePi-Hole Whitelist OS Command Execution
2018-04-15pihole_whitelist_exec.rb