check_http issues...
Marc Powell
marc at ena.com
Thu Jun 5 21:38:49 CEST 2008
On Jun 5, 2008, at 2:08 PM, Victor Lanza wrote:
> 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. :(
I don't know what version of nagios you are using but this appears
relevant and was submitted to nagios-devel late last week --
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=480001
Note also that '!' has special meaning to nagios in service{} and
host{} command_lines regardless of whether it's enclosed in quotes or
not. Nagios-3 addresses that --
http://nagios.sourceforge.net/docs/3_0/whatsnew.html
"Escaped command arguments - You can now pass bang (!) characters in
your command arguments by escaping them with a backslash (\). If you
need to include backslashes in your command arguments, they should
also be escaped with a backslash."
--
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
More information about the Users
mailing list