check_http issues...

Victor Lanza vicjalan at gmail.com
Thu Jun 5 21:08:57 CEST 2008


Ok here is what I tried..

1. I passed the user:pass in the command file opposed to passing as an
$ARGx$ and it returned a Warning state with a 401 Unauthorized. However it
did create the log file this time.

2. I passed the user:pass without the quotes (still in the command file) and
still got the same results in the Nagios interface and also got a log.

What is weird about the log is that the password being sent is not the same
as the one defined in the command file and I guess it has to do with the
'special' characters in the password.

The password is: 123$45!

The reason why I was passing it in single quotes was because the check_http
plugin seemed to be able to pass it on to the site to authenticate with it
just fine. If I removed the quotes, I got an access denied message. However
this only works via the command line.

Here is what I got in the logfiles:

2008-5-5 14:56:58 ------ debugging
cmd=[/usr/local/nagios/libexec/check_http '-H' '10.10.4.10' '-a'
'admin:123$45!$']
output=[HTTP WARNING: HTTP/1.1 401 Unauthorized
]
retcode=1
-------
 2008-5-5 14:58:13 ------ debugging
cmd=[/usr/local/nagios/libexec/check_http '-H' '10.10.4.10' '-a'
'admin:1235!$']
output=[HTTP WARNING: HTTP/1.1 401 Unauthorized
]
retcode=1
-------

Notice how on the first error it has the $ misplaced at the end as well as
after the 3. In the 2nd one it doesn't have $ after 3, it has it at the end
instead. The password is this way due to strict password rules here and I
don't think I could use a simpler one. However, if it works via the command
line I don't see why it shouldn't work through the nagios interface. :(


-----Original Message-----
From: nagios-users-bounces at lists.sourceforge.net
[mailto:nagios-users-bounces at lists.sourceforge.net] On Behalf Of Marc Powell
Sent: Thursday, June 05, 2008 2:46 PM
To: nagios Mailinglist
Subject: Re: [Nagios-users] check_http issues...


On Jun 5, 2008, at 1:28 PM, Victor Lanza wrote:

> Ok....it gets weirder..
>
> When I run the command again with that debug script, the log file  
> doesn't
> get written. All users have access to write to the tmp directory by  
> default
> so I don't know why it is not writing the log.

> /usr/local/nagios/libexec/check_http -I 10.10.4.10 -a admin:'12345'
>>
>>>

What's special about the password that you're enclosing it in quotes?  
Do you see different behavior if you make it wrong, but not 'special'?  
How about if you hard set it in the command{} definition instead of  
passing it as a $ARGx$?

--
Marc

-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
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


-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
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