proxy.pac file ...

From: Marc G. Fournier <marc.fournier@dont-contact.us>
Date: Tue, 12 Oct 1999 02:17:40 -0300 (ADT)

At work, we have a network of some 5k+ students, faculty and staff using
the 'Net, and, now that we have it setup, are being converted over to use
our Proxy server...looks really sweet, until we look closely and see alot
of offcampus accesses being made, and I'd like to reduce that...

We're using the proxy.pac stuff, as descripted that the netscape URl taht
was passed around a little while back, but, being a JavaScript illierate,
am not sure how to extend teh following to do what I want:

 function FindProxyForURL(url, host)
    {
        if (isPlainHostName(host) ||
            dnsDomainIs(host, ".acadiau.ca") ||
            isInNet(host, "131.162.0.0", "255.255.0.0"))
            return "DIRECT";
        else
            return "PROXY proxy.acadiau.ca:3128; DIRECT";
    }

Basically, I want it so that "if myIpAddress() != 131.162.*, return
DIRECT", but...how do you tell JavaScript to do a substring to check the
first 7 characters returned by myIpAddress()?

Thanks...

Marc G. Fournier marc.fournier@acadiau.ca
Senior Systems Administrator Acadia University

  "These are my opinions, which are not necessarily shared by my employer"
Received on Mon Oct 11 1999 - 23:26:33 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:48:47 MST