-if ($outfwsettings{'POLICY'} eq 'MODE1'){
- print "<td width='30%' align='left'><input type='text' name='LOG' maxlength='10' value='$Lang::tr{'inactive'}' readonly='true' /></td>";
-}
-else{
- print "<td width='30%' align='left'><select name='LOG'><option value='$Lang::tr{'active'}' $selected{'LOG'}{$Lang::tr{'active'}}>$Lang::tr{'active'}</option><option value='$Lang::tr{'inactive'}' $selected{'LOG'}{$Lang::tr{'inactive'}}>$Lang::tr{'inactive'}</option></select></td>";
-}
-print <<END
- <td width='20%' align='right' colspan='2' />
- <td width='30%' align='left' colspan='2' />
- <tr><td width='20%' align='right'>$Lang::tr{'destination ip'}: <img src='/blob.gif' />
- <td width='30%' align='left'><input type='text' name='DIP' maxlength='15' value='$outfwsettings{'DIP'}' />
- <td width='20%' align='right' colspan='2'>$Lang::tr{'destination port'}: <img src='/blob.gif' />
- <td width='30%' align='left' colspan='2'><input type='text' name='DPORT' maxlength='11' value='$outfwsettings{'DPORT'}' />
- <tr><td width='20%' align='right'>$Lang::tr{'time'}:</td>
+ my @ipgroups = qx(ls $configpath/ipgroups/);
+ foreach (sort @ipgroups){
+ chomp($_);
+ print "\t\t\t\t\t<option value='$_' $selected{'SNET'}{$_}>$_</option>\n";
+ }
+ print <<END
+ </optgroup>
+ <optgroup label='MAC $Lang::tr{'advproxy NCSA group'}'>
+END
+;
+ my @macgroups = qx(ls $configpath/macgroups/);
+ foreach (sort @macgroups){
+ chomp($_);
+ print "\t\t\t\t\t<option value='$_' $selected{'SNET'}{$_}>$_</option>\n";
+ }
+ print <<END
+ </optgroup>
+ </select>
+ </td>
+ <td align='right' colspan='4'><font color='red'>$Lang::tr{'outgoing firewall warning'}</font></td>
+ </tr>
+ <tr>
+ <td align='right' colspan='4' >$Lang::tr{'source ip or net'}<img src='/blob.gif' /></td>
+ <td align='left' colspan='4' ><input type='text' name='SIP' value='$outfwsettings{'SIP'}' /></td>
+ </tr>
+ <tr>
+ <td align='right' colspan='4' >$Lang::tr{'source'} $Lang::tr{'mac address'}: <img src='/blob.gif' />
+ <td align='left' colspan='4' ><input type='text' name='SMAC' maxlength='23' value='$outfwsettings{'SMAC'}' />
+ </tr>
+ <tr>
+ <td width='20%' align='right'>$Lang::tr{'logging'}:</td>
+ <td width='30%' align='left'>
+ <select name='LOG'>
+ <option value='$Lang::tr{'active'}' $selected{'LOG'}{$Lang::tr{'active'}}>$Lang::tr{'active'}</option>
+ <option value='$Lang::tr{'inactive'}' $selected{'LOG'}{$Lang::tr{'inactive'}}>$Lang::tr{'inactive'}</option>
+ </select>
+ </td>
+ <td width='20%' align='right' colspan='2' />
+ <td width='30%' align='left' colspan='2' />
+ <tr>
+ <td width='20%' align='right'>$Lang::tr{'destination ip or net'}: <img src='/blob.gif' /></td>
+ <td width='30%' align='left'><input type='text' name='DIP' value='$outfwsettings{'DIP'}' /></td>
+ <td width='20%' align='right' colspan='2'>$Lang::tr{'destination port'}(s) <img src='/blob.gif' /></td>
+ <td width='30%' align='left' colspan='2'><input type='text' name='DPORT' value='$outfwsettings{'DPORT'}' /></td>
+ </tr>
+ <tr>
+ <td width='20%' align='right'>$Lang::tr{'time'}:</td>