diff --git a/html/cgi-bin/iptables.cgi b/html/cgi-bin/iptables.cgi index 30fce2721..b52d74fcf 100644 --- a/html/cgi-bin/iptables.cgi +++ b/html/cgi-bin/iptables.cgi @@ -88,7 +88,7 @@ END # start with an Chain the the name, start- and endline of the # chain is extracted into a hash - open (FILE, '/srv/web/ipfire/html/iptables.txt'); + open (FILE, '/var/tmp/iptables.txt'); while (){ $iplines[$lines] = $_; @@ -210,7 +210,7 @@ END # start with an Chain the the name, start- and endline of the # chain is extracted into a hash - open (FILE, '/srv/web/ipfire/html/iptablesmangle.txt'); + open (FILE, '/var/tmp/iptablesmangle.txt'); while (){ $ipmlines[$manlines] = $_; @@ -337,7 +337,7 @@ END # start with an Chain the the name, start- and endline of the # chain is extracted into a hash - open (FILE, '/srv/web/ipfire/html/iptablesnat.txt'); + open (FILE, '/var/tmp/iptablesnat.txt'); while (){ $ipnatlines[$natlines] = $_; @@ -434,6 +434,6 @@ print "
"; &Header::closebigbox(); &Header::closepage(); -system(rm -f "/srv/web/ipfire/html/iptables.txt"); -system(rm -f "/srv/web/ipfire/html/iptablesmangle.txt"); -system(rm -f "/srv/web/ipfire/html/iptablesnat.txt"); +system("rm -f /var/tmp/iptables.txt"); +system("rm -f /var/tmp/iptablesmangle.txt"); +system("rm -f /var/tmp/iptablesnat.txt"); diff --git a/src/misc-progs/getipstat.c b/src/misc-progs/getipstat.c index 38701686e..c806d54a9 100644 --- a/src/misc-progs/getipstat.c +++ b/src/misc-progs/getipstat.c @@ -3,7 +3,7 @@ * Get the list from IPTABLES -L * */ - + #include #include #include @@ -17,11 +17,11 @@ int main(void) { if (!(initsetuid())) exit(1); - - safe_system("/sbin/iptables -L -v -n > /srv/web/ipfire/html/iptables.txt"); - safe_system("/sbin/iptables -L -v -n -t nat > /srv/web/ipfire/html/iptablesnat.txt"); - safe_system("/sbin/iptables -t mangle -L -v -n > /srv/web/ipfire/html/iptablesmangle.txt"); - safe_system("chown nobody.nobody /srv/web/ipfire/html/iptables.txt /srv/web/ipfire/html/iptablesnat.txt /srv/web/ipfire/html/iptablesmangle.txt"); + + safe_system("/sbin/iptables -L -v -n > /var/tmp/iptables.txt"); + safe_system("/sbin/iptables -L -v -n -t nat > /var/tmp/iptablesnat.txt"); + safe_system("/sbin/iptables -t mangle -L -v -n > /var/tmp/iptablesmangle.txt"); + safe_system("chown nobody.nobody /var/tmp/iptables.txt /var/tmp/iptablesnat.txt /var/tmp/iptablesmangle.txt"); return 0; }