Apache CGI Auth Wrong Server Name
Posted: Tue Apr 23, 2013 9:19 am
Hi Folks,
Our previous admin has a Nagios box set up with hostname gshqmon01.domainname.net. However the system is accessed internally by http://nagios
There is a php redirect in /var/www/html/index.php that will redirect users to http://nagios/nagios
This has worked just fine. We recently have to change the access URL to FQDN. I changed the redirect to point to http://nagios.domainname.net/nagios, and while it's successfully redirecting, HTTP basic Auth is now acting strange. I'm required to log in twice; one for the main site, and once for the CGI. Both have the same Auth Realm Name.
For some reason, when you view the basic auth login box for the main site, you'll see: "The server nagios.globalspec.net at Nagios Access requires a username and password"
However when you get the auth login box for the CGI access, it'll show as: "The server nagios at Nagios Access requires a username and password"
Why is the CGI server name different than the site username? It doesn't matter which URL I access the site via, for example, if I use http://gshqmon01.domainname.net/nagios, CGI server name is still nagios.
Any help is greatly appreciated.
Thanks!
Max
Our previous admin has a Nagios box set up with hostname gshqmon01.domainname.net. However the system is accessed internally by http://nagios
There is a php redirect in /var/www/html/index.php that will redirect users to http://nagios/nagios
This has worked just fine. We recently have to change the access URL to FQDN. I changed the redirect to point to http://nagios.domainname.net/nagios, and while it's successfully redirecting, HTTP basic Auth is now acting strange. I'm required to log in twice; one for the main site, and once for the CGI. Both have the same Auth Realm Name.
For some reason, when you view the basic auth login box for the main site, you'll see: "The server nagios.globalspec.net at Nagios Access requires a username and password"
However when you get the auth login box for the CGI access, it'll show as: "The server nagios at Nagios Access requires a username and password"
Why is the CGI server name different than the site username? It doesn't matter which URL I access the site via, for example, if I use http://gshqmon01.domainname.net/nagios, CGI server name is still nagios.
Any help is greatly appreciated.
Thanks!
Max