Forward firewall: commented out line in init.d/firewall that all Forward traffic from green is allowed and put it in rules.pl. Now rules.pl allows this traffic when firewall is set to Mode0 or Mode2

This commit is contained in:
Alexander Marx
2013-01-08 11:20:39 +01:00
committed by Michael Tremer
parent c0ec19967e
commit fd10a52ca2
4 changed files with 13 additions and 17 deletions

0
config/forwardfw/firewall-lib.pl Normal file → Executable file
View File

View File

@@ -88,9 +88,11 @@ if($param eq 'flush'){
&preparerules;
if($MODE eq '0'){
if ($fwdfwsettings{'POLICY'} eq 'MODE1'){
system ("iptables -A $CHAIN -j DROP");
#system ("iptables -A $CHAIN -j DROP");
}elsif($fwdfwsettings{'POLICY'} eq 'MODE2'){
system ("iptables -A $CHAIN -j ACCEPT");
#system ("iptables -A $CHAIN -j ACCEPT");
}elsif($fwdfwsettings{'POLICY'} eq 'MODE0' || $fwdfwsettings{'POLICY'} eq 'MODE2'){
system ("iptables -A $CHAIN -m state --state NEW -j ACCEPT");
}
}
}