summaryrefslogtreecommitdiffstats
path: root/usr/local/www/system_routes_edit.php
diff options
context:
space:
mode:
authorRenato Botelho <garga@FreeBSD.org>2013-05-23 08:05:00 -0300
committerRenato Botelho <garga@FreeBSD.org>2013-05-23 08:05:00 -0300
commit5e2df7fc1c71c2e876e8eb1f99f7b3c8419ea72c (patch)
tree15d9866876cea15647fe39cce8332dbd644d48d5 /usr/local/www/system_routes_edit.php
parent6134dcf51e10cec9c986d4ae17cf8b1bbdda764f (diff)
downloadpfsense-5e2df7fc1c71c2e876e8eb1f99f7b3c8419ea72c.zip
pfsense-5e2df7fc1c71c2e876e8eb1f99f7b3c8419ea72c.tar.gz
Use global aliastable and proper fix #2941
Diffstat (limited to 'usr/local/www/system_routes_edit.php')
-rwxr-xr-xusr/local/www/system_routes_edit.php6
1 files changed, 4 insertions, 2 deletions
diff --git a/usr/local/www/system_routes_edit.php b/usr/local/www/system_routes_edit.php
index ed9362a..a65db4a 100755
--- a/usr/local/www/system_routes_edit.php
+++ b/usr/local/www/system_routes_edit.php
@@ -84,6 +84,8 @@ if (isset($_GET['dup']))
if ($_POST) {
+ global $aliastable;
+
unset($input_errors);
$pconfig = $_POST;
@@ -126,8 +128,8 @@ if ($_POST) {
} elseif (is_alias($_POST['network'])) {
$osn = $_POST['network'];
$fqdn_found = 0;
- foreach (filter_expand_alias_array($_POST['network'], true) as $tgt) {
- if (!is_ipaddr($tgt) && is_hostname($tgt)) {
+ foreach (preg_split('/\s+/', $aliastable[$osn]) as $tgt) {
+ if (!is_ipaddr($tgt)) {
if ($fqdn_found === 0) {
$input_errors[] = sprintf(gettext("The alias (%s) has one or more FQDNs configured and cannot be used to configure a static route."), $_POST['network']);
$fqdn_found = 1;
OpenPOWER on IntegriCloud