mirror of
https://github.com/pi-hole/web.git
synced 2026-04-24 18:59:48 +01:00
Execute pihole through wrapper
All different exec() calls basically just calls sudo pihole, with various different syntaxes. Using a wrapper function allows sanitization of arguments for better safety. Signed-off-by: Samu Voutilainen <smar@smar.fi>
This commit is contained in:
@@ -439,7 +439,7 @@ if(isset($_POST["action"]))
|
||||
|
||||
if($importedsomething)
|
||||
{
|
||||
exec("sudo pihole restartdns reload");
|
||||
pihole_execute("restartdns reload");
|
||||
}
|
||||
|
||||
unlink($fullfilename);
|
||||
|
||||
Reference in New Issue
Block a user