summaryrefslogtreecommitdiffstats
path: root/usr/local/www/wizard.php
diff options
context:
space:
mode:
authorErik Fonnesbeck <efonnes@gmail.com>2010-11-18 02:11:36 -0700
committerErik Fonnesbeck <efonnes@gmail.com>2010-11-18 02:34:51 -0700
commit0bee20108d6e6f5750b0164a3740a75bb411b77f (patch)
tree958a6d65d7a199df3adc7d0192d9ee68d204c3d4 /usr/local/www/wizard.php
parentb8d4d7cdc5e89ca5ef41ee69fcc4d74f494db573 (diff)
downloadpfsense-0bee20108d6e6f5750b0164a3740a75bb411b77f.zip
pfsense-0bee20108d6e6f5750b0164a3740a75bb411b77f.tar.gz
Save the host name and domain to a temporary location until the setup wizard is finished to prevent triggering the DNS rebind message. Fixes #1022 Also use this information to implement the redirect for changed host for ticket #455
Diffstat (limited to 'usr/local/www/wizard.php')
-rwxr-xr-xusr/local/www/wizard.php5
1 files changed, 4 insertions, 1 deletions
diff --git a/usr/local/www/wizard.php b/usr/local/www/wizard.php
index d52c738..493fab1 100755
--- a/usr/local/www/wizard.php
+++ b/usr/local/www/wizard.php
@@ -930,7 +930,10 @@ function fixup_string($string) {
if ($host_if && is_ipaddr($config['interfaces'][$host_if]['ipaddr']))
$urlhost = $config['interfaces'][$host_if]['ipaddr'];
}
- }
+ } else if ($urlhost == $config['system']['hostname'])
+ $urlhost = $config['wizardtemp']['system']['hostname'];
+ else if ($urlhost == $config['system']['hostname'] . '.' . $config['system']['domain'])
+ $urlhost = $config['wizardtemp']['system']['hostname'] . '.' . $config['wizardtemp']['system']['domain'];
}
if($urlhost != $http_host)
file_put_contents("{$g['tmp_path']}/setupwizard_lastreferrer", $proto . "://" . $http_host . $urlport . $_SERVER['REQUEST_URI']);
OpenPOWER on IntegriCloud