Nagios via Proxy and NTLM HTTP site


#1

Hi there!

I am completely new to Nagios and am having a hard time wrapping my head around it all. I am very very limited *nix experience so that compounds things.

I have a trial version of Nagios XI set up as a VM, and one of the functions I need to set up is monitoring a website. Simple right? The website however requires NTLM authentication, it’s an intranet site. Additionally, is it possible to force Nagios to go through a proxy server for this site and this site only? Reason being this intranet site is from a merged with company, so it’s in a different location and they have set firewall rules to allow only traffic from our proxy to hit their intranet web server.

Ultimately, I would prefer to be able to do this in Nagios free but for the immediate future Nagios XI will have to do with some small hope my company will actually pay for the full thing!


#2

By Proxy, is this a Socks or HTTP proxy? For Socks I’d point you at tsocks, but it’s not part of NagiosXI at the moment. For HTTP proxy the /UNIX/ convention is to set the environment variable HTTP_PROXY=“http:///” like so.

The http check as shipped does not support NTLM, but you can put one of these into /usr/local/nagios/libexec and use it. This works out well for you as the curl program supports both types of proxy and NTLM, so it should be easy for you to adapt the check_http_ntlm plugin to suit your needs. The check_http_ntlm.pl also uses curl, but it might not be so easy to alter a perl program as it is for a shell script, YMMV(Your mileage may vary).

http://exchange.nagios.org/directory/Plugins/Network-Protocols/HTTP/check_http_ntlm/details
http://exchange.nagios.org/directory/Plugins/Network-Protocols/HTTP/check_http_ntlm-2Epl/details

I’ll plan to package support for NTLM as a module soonish.

For more options take a look here:
http://exchange.nagios.org/directory/Plugins/Network-Protocols/HTTP


#3

curl --help; # Shows all the proxy arguments you could ever want… in 2010: --socks4, --socks5, -x/–proxy and -U for authentication to the Proxy.