X-Git-Url: http://git.ipfire.org/?p=people%2Fteissler%2Fipfire-2.x.git;a=blobdiff_plain;f=html%2Fcgi-bin%2Foutgoingfw.cgi;h=27a8927e6c1258f4209339900977d8db59c832f2;hp=a9e8d92d8df9c7384d5b9cf0242648b5c86f9f3d;hb=caf4eb1adc5c18fb54a5296e85e3726439b34abe;hpb=15af725ea401ba1436abd848080e62188e79e4be diff --git a/html/cgi-bin/outgoingfw.cgi b/html/cgi-bin/outgoingfw.cgi index a9e8d92d8..27a8927e6 100644 --- a/html/cgi-bin/outgoingfw.cgi +++ b/html/cgi-bin/outgoingfw.cgi @@ -2,7 +2,7 @@ ############################################################################### # # # IPFire.org - A linux based firewall # -# Copyright (C) 2005-2010 IPTifre Team # +# Copyright (C) 2005-2010 IPFire Team # # # # This program is free software: you can redistribute it and/or modify # # it under the terms of the GNU General Public License as published by # @@ -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 ; @@ -462,14 +467,22 @@ END END ; if (($outfwsettings{'SIP'}) || ($outfwsettings{'SMAC'})) { - unless ($outfwsettings{'SIP'}) { $outfwsettings{'DISPLAY_SIP'} = 'ALL'; } else { $outfwsettings{'DISPLAY_SIP'} = $outfwsettings{'SIP'}; } - unless ($outfwsettings{'SMAC'}) { $outfwsettings{'DISPLAY_SMAC'} = 'ALL'; } else { $outfwsettings{'DISPLAY_SMAC'} = $outfwsettings{'SMAC'}; } - print <$Lang::tr{'source ip or net'}: - $outfwsettings{'DISPLAY_SIP'} - -END -; + + unless ($outfwsettings{'SIP'}) { + $outfwsettings{'DISPLAY_SIP'} = 'ALL'; + } else { + $outfwsettings{'DISPLAY_SIP'} = $outfwsettings{'SIP'}; + } + + unless ($outfwsettings{'SMAC'}) { + $outfwsettings{'DISPLAY_SMAC'} = 'ALL'; + print "$Lang::tr{'source ip or net'}: "; + print "$outfwsettings{'DISPLAY_SIP'}"; + } else { + $outfwsettings{'DISPLAY_SMAC'} = $outfwsettings{'SMAC'}; + print "$Lang::tr{'source'} $Lang::tr{'mac address'}: "; + print "$outfwsettings{'DISPLAY_SMAC'}"; + } } print <$Lang::tr{'time'} - @@ -559,13 +572,13 @@ END if ($p2pline[2] eq 'on') { print < - + END ; } else { print < - + END ; } @@ -576,7 +589,7 @@ END } print < -
$Lang::tr{'outgoingfw p2p description'} +
$Lang::tr{'outgoing firewall p2p description 1'} $Lang::tr{ $Lang::tr{'outgoing firewall p2p description 2'} $Lang::tr{ $Lang::tr{'outgoing firewall p2p description 3'} END ; &Header::closebox(); @@ -586,9 +599,9 @@ END print < - - - + + + - + - - + + + + + + + +
$Lang::tr{'mode'} 0:$Lang::tr{'outgoingfw mode0'}
$Lang::tr{'mode'} 1:$Lang::tr{'outgoingfw mode1'}
$Lang::tr{'mode'} 2:$Lang::tr{'outgoingfw mode2'}
$Lang::tr{'mode'} 0:$Lang::tr{'outgoing firewall mode0'}
$Lang::tr{'mode'} 1:$Lang::tr{'outgoing firewall mode1'}
$Lang::tr{'mode'} 2:$Lang::tr{'outgoing firewall mode2'}

@@ -597,7 +610,7 @@ END ; if ($outfwsettings{'POLICY'} ne 'MODE0') { print < + $Lang::tr{'outgoing firewall reset'}: END ; } @@ -627,7 +640,7 @@ print <
$Lang::tr{'protocol'}:$Lang::tr{'protocol'} + + + - @@ -675,19 +690,35 @@ END } print < - + END ; my @ipgroups = qx(ls $configpath/ipgroups/); foreach (sort @ipgroups){ print "\t\t\t\t\t\n"; } + print < + +END +; + my @macgroups = qx(ls $configpath/macgroups/); + foreach (sort @macgroups){ + print "\t\t\t\t\t\n"; + } print < $Lang::tr{'source ip or net'}$Lang::tr{'outgoing firewall warning'}
$Lang::tr{'source ip or net'}
$Lang::tr{'source'} $Lang::tr{'mac address'}: +
$Lang::tr{'logging'}: