mirror of
https://github.com/pfsense/pfsense.git
synced 2025-10-26 11:38:35 +00:00
fix reject rules to the same as in 1_2. return is valid on all rules
This commit is contained in:
parent
a29dc11b12
commit
e91baab820
@ -1361,16 +1361,7 @@ function filter_generate_user_rule($rule)
|
||||
$type = "pass ";
|
||||
}
|
||||
if ($type == "reject") {
|
||||
/* special reject packet */
|
||||
if ($rule['protocol'] == "tcp") {
|
||||
$aline['type'] = "block return-rst ";
|
||||
} else if ($rule['protocol'] == "udp") {
|
||||
$aline['type'] = "block return-icmp ";
|
||||
} else if ($rule['protocol'] == "tcp/udp") {
|
||||
$aline['type'] = "block return ";
|
||||
} else {
|
||||
$aline['type'] = "block ";
|
||||
}
|
||||
$aline['type'] = "block return ";
|
||||
} else
|
||||
$aline['type'] = $type . " ";
|
||||
if (isset($rule['floating']) && $rule['floating'] == "yes") {
|
||||
@ -2406,4 +2397,4 @@ EOD;
|
||||
return($ipfrules);
|
||||
}
|
||||
|
||||
?>
|
||||
?>
|
||||
@ -369,10 +369,7 @@ echo "<script type=\"text/javascript\" language=\"javascript\" src=\"/javascript
|
||||
<?php if ($filterent['type'] == "block")
|
||||
$iconfn = "block";
|
||||
else if ($filterent['type'] == "reject") {
|
||||
if ($filterent['protocol'] == "tcp" || $filterent['protocol'] == "udp" || $filterent['protocol'] == "tcp/udp")
|
||||
$iconfn = "reject";
|
||||
else
|
||||
$iconfn = "block";
|
||||
$iconfn = "reject";
|
||||
} else
|
||||
$iconfn = "pass";
|
||||
if (isset($filterent['disabled'])) {
|
||||
|
||||
@ -529,7 +529,7 @@ include("head.inc");
|
||||
<br/>
|
||||
<span class="vexpl">
|
||||
Choose what to do with packets that match the criteria specified below. <br/>
|
||||
Hint: the difference between block and reject is that with reject, a packet (TCP RST or ICMP port unreachable for UDP) is returned to the sender, whereas with block the packet is dropped silently. In either case, the original packet is discarded. Reject only works when the protocol is set to either TCP or UDP (but not "TCP/UDP") below.
|
||||
Hint: the difference between block and reject is that with reject, a packet (TCP RST or ICMP port unreachable for UDP) is returned to the sender, whereas with block the packet is dropped silently. In either case, the original packet is discarded.
|
||||
</span>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user