From c028fefa303c86c22cbfe5ab32394c8e88c7567a Mon Sep 17 00:00:00 2001 From: Tom Eastep Date: Fri, 24 Jul 2009 17:27:42 -0700 Subject: [PATCH] Fix 'disable_ipv6 -- take 2 --- Shorewall/Perl/prog.footer | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Shorewall/Perl/prog.footer b/Shorewall/Perl/prog.footer index cd1a5e23a..20708fa11 100644 --- a/Shorewall/Perl/prog.footer +++ b/Shorewall/Perl/prog.footer @@ -32,9 +32,11 @@ clear_firewall() { echo 1 > /proc/sys/net/ipv4/ip_forward if [ -n "$DISABLE_IPV6" ]; then - $IP6TABLES -P INPUT ACCEPT 2> /dev/null - $IP6TABLES -P OUTPUT ACCEPT 2> /dev/null - $IP6TABLES -P FORWARD ACCEPT 2> /dev/null + if [ -x $IPTABLES ]; then + $IP6TABLES -P INPUT ACCEPT 2> /dev/null + $IP6TABLES -P OUTPUT ACCEPT 2> /dev/null + $IP6TABLES -P FORWARD ACCEPT 2> /dev/null + fi fi run_clear_exit