Remove SIP und SMAC if SNET is set to all, this avoids some false rules.
authorChristian Schmidt <christian.schmidt@ipfire.org>
Mon, 6 Sep 2010 06:46:59 +0000 (08:46 +0200)
committerChristian Schmidt <christian.schmidt@ipfire.org>
Mon, 6 Sep 2010 06:46:59 +0000 (08:46 +0200)
html/cgi-bin/outgoingfw.cgi

index 07fcb39..27a8927 100644 (file)
@@ -310,6 +310,11 @@ if ($outfwsettings{'ACTION'} eq $Lang::tr{'delete'})
 if ($outfwsettings{'ACTION'} eq $Lang::tr{'add'})
 {
        if ( $outfwsettings{'VALID'} eq 'yes' ) {
+
+               if ( $outfwsettings{'SNET'} eq "all" ) {
+                       $outfwsettings{'SIP'} ="";
+                       $outfwsettings{'SMAC'}="";
+               }
                open( FILE, ">> $configfile" ) or die "Unable to write $configfile";
                print FILE <<END
 $outfwsettings{'STATE'};$outfwsettings{'ENABLED'};$outfwsettings{'SNET'};$outfwsettings{'PROT'};$outfwsettings{'NAME'};$outfwsettings{'SIP'};$outfwsettings{'SMAC'};$outfwsettings{'DIP'};$outfwsettings{'DPORT'};$outfwsettings{'LOG'};$outfwsettings{'TIME_MON'};$outfwsettings{'TIME_TUE'};$outfwsettings{'TIME_WED'};$outfwsettings{'TIME_THU'};$outfwsettings{'TIME_FRI'};$outfwsettings{'TIME_SAT'};$outfwsettings{'TIME_SUN'};$outfwsettings{'TIME_FROM'};$outfwsettings{'TIME_TO'};