mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-17 01:54:49 +00:00
Firewall, validate port alias... wrong order, causing disabled snat rule.
This commit is contained in:
parent
a435f74707
commit
188afed620
@ -98,12 +98,12 @@ class SNatRule extends Rule
|
||||
}
|
||||
foreach (array("sourceport", "dstport", "natport") as $fieldname) {
|
||||
if (!empty($rule[$fieldname]) && Util::isAlias($rule[$fieldname])) {
|
||||
$rule[$fieldname] = "$".$rule[$fieldname];
|
||||
if (!Util::isAlias($rule[$fieldname], true)) {
|
||||
// unable to map port
|
||||
$this->log("SNAT / unable to map port ". $rule[$fieldname]. ", empty?");
|
||||
$rule['disabled'] = true;
|
||||
}
|
||||
$rule[$fieldname] = "$".$rule[$fieldname];
|
||||
}
|
||||
}
|
||||
if (!empty($rule['staticnatport']) || !empty($rule['nonat'])) {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user