Escape constant, arg + extension

This commit is contained in:
billz 2021-05-02 07:15:12 +01:00
parent 90aea4ca93
commit 4baac6eae2

View file

@ -7,7 +7,7 @@ $interface = $_POST['iface'];
if (isset($interface)) {
// fetch dnsmasq.conf settings for interface
exec('cat '. RASPI_DNSMASQ_PREFIX.escapeshellarg($interface).'.conf', $return);
exec('cat '. escapeshellarg(RASPI_DNSMASQ_PREFIX.$interface.'.conf'), $return);
$conf = ParseConfig($return);
$dhcpdata['DHCPEnabled'] = empty($conf) ? false : true;