Nagios cannot detect user

Marc Powell marc at ena.com
Mon Feb 13 17:33:49 CET 2006



> -----Original Message-----
> From: nagios-users-admin at lists.sourceforge.net [mailto:nagios-users-
> admin at lists.sourceforge.net] On Behalf Of Matteo Corti
> Sent: Monday, February 13, 2006 2:30 AM
> To: nagios-users at lists.sourceforge.net
> Subject: [Nagios-users] Nagios cannot detect user
> 
> Hi,
> 
> I access nagios (2.0) through Apache and SSL (see below for the
> configuration)
> As expected Apache asks me to authenticate when loading the page but
> nagios is not able to get my user name. In the tactical overview I
see:
> 
>   Tactical Monitoring Overview
>   Last Updated: Mon Feb 13 09:24:30 CET 2006
>   Updated every 90 seconds
>   Nagios(r) - www.nagios.org
>   Logged in as ?
> 
> Since I am using authentication (use_authentication=1) I am not able
to
> access all the information pages.
> 
> If I set the default user everything works like a charm (i.e., the
rest
> of the configuration seems OK).
> 
> Many thanks for any hint.
> 
> Matteo
> 
> ================
> httpd.conf
> 
> # Force SSL
> RewriteEngine On
> RewriteLogLevel 0
> RewriteCond %{HTTPS} "off"
> RewriteRule ^/nagios(.*)  https://%{HTTP_HOST}/nagios$1
[L,R=permanent]
> 
> # For SSL-servers
> ScriptAlias /nagios/cgi-bin /usr/lib/nagios/cgi
> <Directory "/usr/lib/nagios/cgi-bin">
>    Options ExecCGI
>    SSLRequireSSL
>    AllowOverride None
>    Order allow,deny
>    Allow from all
>    AuthName "Nagios Access"
>    AuthType Basic
>    AuthUserFile /etc/nagios/htpasswd
>    Require valid-user
> </Directory>

I believe this is your problem. If the nagios cgi's truly live in
/usr/lib/nagios/cgi, then the auth restrictions are not applied where
they're needed. You're applying them to the wrong directory,
/usr/lib/nagios/cgi-bin.

You're being prompted to log in because the auth restrictions to the
html directory _are_ working but that doesn't matter since the CGI's,
that need to see the auth info, are in another directory.

--
Marc


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid3432&bid#0486&dat1642
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list