summaryrefslogtreecommitdiffstats
path: root/src/etc
diff options
context:
space:
mode:
authorDenny Page <dennypage@me.com>2016-02-19 22:13:40 -0800
committerDenny Page <dennypage@me.com>2016-02-19 22:13:40 -0800
commite3f1065671b395b96ff92cc25185ac7a29d1b241 (patch)
tree00f4597acb6112890001eb36b8297fe099855df6 /src/etc
parent81742ea234459c423c7425eb55e65f571419c7d1 (diff)
parent7a9f877471f2e4e48ab98d69b824236dee36c7b8 (diff)
downloadpfsense-e3f1065671b395b96ff92cc25185ac7a29d1b241.zip
pfsense-e3f1065671b395b96ff92cc25185ac7a29d1b241.tar.gz
Merge branch 'master' of https://github.com/pfsense/pfsense
Diffstat (limited to 'src/etc')
-rw-r--r--src/etc/inc/util.inc19
1 files changed, 18 insertions, 1 deletions
diff --git a/src/etc/inc/util.inc b/src/etc/inc/util.inc
index 92149ff..9a28436 100644
--- a/src/etc/inc/util.inc
+++ b/src/etc/inc/util.inc
@@ -1701,13 +1701,27 @@ function alias_get_type($name) {
/* expand a host or network alias, if necessary */
function alias_expand($name) {
- global $aliastable;
+ global $config, $aliastable;
+ $urltable_prefix = "/var/db/aliastables/";
+ $urltable_filename = $urltable_prefix . $name . ".txt";
if (isset($aliastable[$name])) {
// alias names cannot be strictly numeric. redmine #4289
if (is_numericint($name)) {
return null;
}
+ // make sure if it's a ports alias, it actually exists. redmine #5845
+ foreach ($config['aliases']['alias'] as $alias) {
+ if ($alias['name'] == $name) {
+ if ($alias['type'] == "urltable_ports") {
+ if (is_URL($alias['url']) && file_exists($urltable_filename) && filesize($urltable_filename)) {
+ return "\${$name}";
+ } else {
+ return null;
+ }
+ }
+ }
+ }
return "\${$name}";
} else if (is_ipaddr($name) || is_subnet($name) || is_port($name) || is_portrange($name)) {
return "{$name}";
@@ -2052,6 +2066,9 @@ function is_interface_vlan_mismatch() {
if (is_array($config['vlans']['vlan'])) {
foreach ($config['vlans']['vlan'] as $vlan) {
+ if (substr($vlan['if'], 0, 4) == "lagg") {
+ return false;
+ }
if (does_interface_exist($vlan['if']) == false) {
return true;
}
OpenPOWER on IntegriCloud