Add parens around NAT reflection rule interface. Fixes #9446

This commit is contained in:
jim-p 2019-04-01 08:29:44 -04:00
parent 1f606f11bd
commit 8800ee6f90

View File

@ -1369,7 +1369,7 @@ function filter_generate_reflection_nat($rule, &$route_table, $nat_ifs, $protoco
/* Do not generate a rule with an interface source if that interface has no IP address.
* See https://redmine.pfsense.org/issues/8604 */
if (!empty(get_interface_ip($subnet_if))) {
$natrules .= "no nat on {$subnet_if}{$protocol_text} from {$subnet_if} to {$target}\n";
$natrules .= "no nat on {$subnet_if}{$protocol_text} from ({$subnet_if}) to {$target}\n";
}
$natrules .= "nat on {$subnet_if}{$protocol_text} from {$subnet} to {$target} -> {$ifsubnet_ip}{$static_port}\n";
}