CGI problems i cannot figure out
Posted: Fri Sep 07, 2012 4:54 am
I got a bit of a problem which i do not seem to be able to tackle. I am hoping you lads might have had more luck when standing in line for the brainy part...
When connecting to my nagios machine it tells me:
Now, i strongly believe this to be an error, so i checked the configuration a bit. First off, i must say it's a Debian machine with native APT installed Nagios on it. However, some tweaks have been done. This will explain the path and such. Think i better just put down parts of the config file. I do not think the problem is in nagios's cgi.cfg. This one seems correct:
/etc/nagios3/cgi.cfg
Here you see that the accounts should have access. I have confirmed this by actually going so far as to build a new machine, copy it's cgi config file over the one i had (so the clean on that works on new machine). This did not solve the problem, so a logical conclusion would be that the problem is not here.
A different location could be the Apache config, tho i doubt it.
/etc/apache2/conf.d/nagios3.conf
Than the last file to check would be the htpasswd.users. This one is fine. Take it from me, i can log into the interface in the first place, so it should be fine.
Is there one of you fellows that spots my idiotic mistake??
When connecting to my nagios machine it tells me:
Code: Select all
It appears as though you do not have permission to view information for any of the hosts you requested
If you believe this is an error, check the HTTP server authentication requirements for accessing this CGI
and check the authorization options in your CGI configuration file.
/etc/nagios3/cgi.cfg
Code: Select all
use_authentication=1
use_ssl_authentication=0
authorized_for_system_information=*
authorized_for_configuration_information=*
authorized_for_system_commands=*
authorized_for_all_services=*
authorized_for_all_hosts=*
authorized_for_all_service_commands=*
authorized_for_all_host_commands=*
A different location could be the Apache config, tho i doubt it.
/etc/apache2/conf.d/nagios3.conf
Code: Select all
ScriptAlias /cgi-bin/nagios3 /usr/lib/cgi-bin/nagios3
ScriptAlias /nagios3/cgi-bin /usr/lib/cgi-bin/nagios3
Alias /nagios3/stylesheets /etc/nagios3/stylesheets
Alias /nagios3 /usr/share/nagios3/htdocs
<DirectoryMatch (/usr/share/nagios3/htdocs|/usr/lib/cgi-bin/nagios3|/etc/nagios3/stylesheets)>
Options FollowSymLinks
DirectoryIndex index.php
AllowOverride AuthConfig
Order Allow,Deny
Allow From All
AuthName "Nagios Access"
AuthType Basic
AuthUserFile /etc/nagios3/htpasswd.users
# nagios 1.x:
#AuthUserFile /etc/nagios/htpasswd.users
require valid-user
</DirectoryMatch>
Is there one of you fellows that spots my idiotic mistake??