Xymon Mailing List Archive search

Testing external web through a proxy

list Ralph Mitchell
Fri, 21 Nov 2008 09:23:03 -0600
Message-Id: <user-cb7b574dd3fd@xymon.invalid>

Looks like your proxy requires authentication via Kerberos or NTLM or
GSS-Negotiate.  Dunno if Xymon can do those.  Luckily the curl tool
(httpp://curl.haxx.se) *can* do those...  I haven't had to use them, but it
should not be too hard to bang out an ext script to do the check.  Something
along these lines:

     #!/bin/sh
     curl -x http://ourproxy.ourdomain.com:8080 \
           --proxy-anyauth -U hobbituser:hobbitpassword \
           -s -S -L -o /dev/null http://www.google.com/
     if [ "$?" -eq "0" ]; then
       COLOR=green
       MESSAGE="Pinged Google OK"
     else
       COLOR=RED
       MESSAGE="Failed to reach Google"
     fi
     $BB $BBDISP "status www,google,com.home $COLOR `date`
$MESSAGE"

Obviously that can be expanded quite a lot...  :)  Drop it somewhere on your
Xymon server (maybe in server/ext) and set up a block in
server/etc/hobbitlaunch.cfg to fire it off as often as you want.  You may
need to give the full path for curl, which is probably /usr/bin/curl.

Ralph Mitchell


On Fri, Nov 21, 2008 at 1:30 AM, Everett, Vernon <
user-9da1a1882f49@xymon.invalid> wrote:
 Hi all

I am trying to test our interent connectivity by checking Google through
our proxy.
(Once I get this right, I want to start testing some of our external web
pages in the same manner)

I have configured this in bb-hosts
0.0.0.0         *www.google.com* <http://www.google.com>;          # noconn
• http://hobbituser:user-1b7da96bb10f@xymon.invalid:8080/http://www.google.com
*<http://hobbituser:user-1b7da96bb10f@xymon.invalid:8080/http://www.google.com>;

And I get this.
 *yellow* <http://hobbit/hobbit/gifs/yellow.gif>; *
http://www.google.com.au/* <http://www.google.com.au/>; - Proxy
Authentication Required

HTTP/1.1 407 Proxy Authentication Required ( The ISA Server requires
authorization to fulfill the request. Access to the Web Proxy filter is
denied.  )
Via: 1.1 PXYHOSTNAME
Proxy-Authenticate: Negotiate
Proxy-Authenticate: Kerberos
Proxy-Authenticate: NTLM
Connection: Keep-Alive
Proxy-Connection: Keep-Alive
Pragma: no-cache
Cache-Control: no-cache
Content-Type: text/html
Content-Length: 4118

Seconds:     0.02

Any assistance appreciated.

Regards
    Vernon


NOTICE: This email and any attachments are confidential.
They may contain legally privileged information or
copyright material. You must not read, copy, use or
disclose them without authorisation. If you are not an
intended recipient, please contact us at once by return
email and then delete both messages and all attachments.