summaryrefslogtreecommitdiffstats
path: root/etc/inc/auth.inc
diff options
context:
space:
mode:
authorsmos <seth.mos@dds.nl>2011-08-21 18:45:40 +0200
committersmos <seth.mos@dds.nl>2011-08-21 18:45:40 +0200
commit4fcab77bf1302423fbb2f2e725163430bf75b08d (patch)
treee9b4cdeb345d1c41dd5f56560d557dbfac420810 /etc/inc/auth.inc
parent826ac52c6858b8f47d5b3a58f9f7e052ff2f1f8b (diff)
downloadpfsense-4fcab77bf1302423fbb2f2e725163430bf75b08d.zip
pfsense-4fcab77bf1302423fbb2f2e725163430bf75b08d.tar.gz
Unbreak the DNS rebind check when accessing over IPv4
Diffstat (limited to 'etc/inc/auth.inc')
-rw-r--r--etc/inc/auth.inc3
1 files changed, 2 insertions, 1 deletions
diff --git a/etc/inc/auth.inc b/etc/inc/auth.inc
index b551be0..1dac82e 100644
--- a/etc/inc/auth.inc
+++ b/etc/inc/auth.inc
@@ -69,7 +69,8 @@ if (function_exists("display_error_form") && !isset($config['system']['webgui'][
$http_host = str_replace(array("[", "]"), "", implode(":", $http_host_port));
}
} else {
- $http_host = $_SERVER['HTTP_HOST'];
+ $http_host = explode(":", $_SERVER['HTTP_HOST']);
+ $http_host = $http_host[0];
}
if(is_ipaddr($http_host) or $_SERVER['SERVER_ADDR'] == "127.0.0.1" or
strcasecmp($http_host, "localhost") == 0 or $_SERVER['SERVER_ADDR'] == "::1")
OpenPOWER on IntegriCloud