$outfwsettings{'ACTION'} = 'Add rule';
}
}
-if ($outfwsettings{'ACTION'} eq 'Add rule')
+if ($outfwsettings{'ACTION'} eq $Lang::tr{'Add Rule'})
{
&addrule();
exit
&Header::openbox('100%', 'center', 'Rules');
print <<END
<form method='post' action='$ENV{'SCRIPT_NAME'}'>
- <input type='submit' name='ACTION' value='Add rule' />
+ <input type='submit' name='ACTION' value='$Lang::tr{'Add Rule'}' />
</form>
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 <<END
- <tr><td width='14%' align='right'>$Lang::tr{'source ip or net'}:
- <td width='14%' align='left'>$outfwsettings{'DISPLAY_SIP'}
- <td width='44%' colspan='2' align='center'>
-END
-;
+
+ unless ($outfwsettings{'SIP'}) {
+ $outfwsettings{'DISPLAY_SIP'} = 'ALL';
+ } else {
+ $outfwsettings{'DISPLAY_SIP'} = $outfwsettings{'SIP'};
+ }
+
+ unless ($outfwsettings{'SMAC'}) {
+ $outfwsettings{'DISPLAY_SMAC'} = 'ALL';
+ print "<tr><td /><td align='left'>$Lang::tr{'source ip or net'}: </td>";
+ print "<td align='left' colspan='2'>$outfwsettings{'DISPLAY_SIP'}</td>";
+ } else {
+ $outfwsettings{'DISPLAY_SMAC'} = $outfwsettings{'SMAC'};
+ print "<tr><td /><td align='left'>$Lang::tr{'source'} $Lang::tr{'mac address'}: </td>";
+ print "<td align='left' colspan='2'>$outfwsettings{'DISPLAY_SMAC'}</td>";
+ }
}
print <<END
<tr><td width='14%' align='right'>$Lang::tr{'time'} - </td>
<td width='30%' align='left' colspan='2'><input type='checkbox' name='ENABLED' $selected{'ENABLED'} /></td>
</tr>
<tr>
- <td width='20%' align='right'>$Lang::tr{'protocol'}:</td>
+ <td width='20%' align='right'>$Lang::tr{'protocol'}</td>
<td width='30%' align='left'>
<select name='PROT'>
<option value='all' $selected{'PROT'}{'all'}>All</option>
<select name='SNET'>
<optgroup label='---'>
<option value='all' $selected{'SNET'}{'ALL'}>$Lang::tr{'all'}</option>
+ <optgroup label='$Lang::tr{'mac address'}'>
+ <option value='mac' $selected{'SNET'}{'mac'}>$Lang::tr{'source'} $Lang::tr{'mac address'}</option>
+ </optgroup>
<optgroup label='$Lang::tr{'ip address'}'>
<option value='ip' $selected{'SNET'}{'ip'}>$Lang::tr{'source ip or net'}</option>
<option value='red' $selected{'SNET'}{'red'}>$Lang::tr{'red'} IP</option>
}
print <<END
</optgroup>
- <optgroup label='$Lang::tr{'advproxy NCSA group'}'>
+ <optgroup label='IP $Lang::tr{'advproxy NCSA group'}'>
END
;
my @ipgroups = qx(ls $configpath/ipgroups/);
foreach (sort @ipgroups){
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){
+ print "\t\t\t\t\t<option value='$_' $selected{'SNET'}{'$_'}>$_</option>\n";
+ }
print <<END
</optgroup>
</select>
</td>
- <td width='20%' align='right' colspan='2'>$Lang::tr{'source ip or net'}<img src='/blob.gif' /></td>
- <td width='30%' align='left' colspan='2'><input type='text' name='SIP' value='$outfwsettings{'SIP'}' /></td>
+ <td align='right' colspan='4'><font color='red'>$Lang::tr{'outgoingfw 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>