We have a network topology like below. www.space.se ----+----- Big Bad Internet ( www.smurf.com ) | | Firewall ( Filters out javascripts and such ) | | Proxy ( wwwgate port 3128 ) ( Filters out virii ) | | ntweb ---+--- unixweb | | Client with NT2000, IE5.5SP2 Client with NT2000, IE6 Client with NT4, IE5.5SP2 The functionality we are after should be like this ntweb - Connect Direct ntweb.space.se - Connect Direct unixweb - Connect Direct unixweb.space.se - Connect Direct www - Proxy connect www.space.se - Proxy connect big.bad.int - Proxy connect This functionality is received by using Netscape and the following script ============================================== Test 1: function FindProxyForURL(url, host) { if ( isPlainHostName(host) || dnsDomainIs(host, ".space.se") || isInNet(host, "10.0.0.0", "255.0.0.0")) if ( localHostOrDomainIs(host, "outer") || localHostOrDomainIs(host,"www") || localHostOrDomainIs(host,"outer.space.se") || localHostOrDomainIs(host,"www.space.se")) return "PROXY wwwgate:3128"; else return "DIRECT"; else return "PROXY wwwgate:3128"; } Using this, I get: ntweb - Proxy connect ntweb.space.se - Connect Direct unixweb - Proxy connect unixweb.space.se - Connect Direct www - Proxy connect www.space.se - Proxy connect big.bad.int - Proxy connect I then started to read up on microsofts webpages on the subject of Automatic Proxy Configuration Scripts, and found teh following resource: http://www.microsoft.com/windows/ieak/techinfo/deploy/60/en/corpexjs.htm Using example 2 from that page I get the following: ====================================================== Test 2: function FindProxyForURL(url, host) { if ((isPlainHostName(host) || dnsDomainIs(host, ".space.se")) && !localHostOrDomainIs(host, "www.space.se") && !localHostOrDomainIs(host, "outer.space.se")) return "DIRECT"; else return "PROXY wwwgate.space.se:3128"; } Using this, I get: ntweb - Proxy connect ntweb.space.se - Connect Direct unixweb - Proxy connect unixweb.space.se - Connect Direct www - Proxy connect www.space.se - Proxy connect big.bad.int - Proxy connect Very well, Back to my search for a script that will work as advertised. ============================================================= Using example 1 like going back to basics. function FindProxyForURL(url, host) { if (isPlainHostName(host)) return "DIRECT"; else return "PROXY wwwgate.space.se:3128"; } Using this, I get: ntweb - Connect Direct ntweb.space.se - Proxy connect unixweb - Connect Direct unixweb.space.se - Proxy connect www - search.msn.com ??? www.space.se - Proxy connect big.bad.int - Proxy connect Once again almost there. Wonder why it prefers search.msn.com instead of using DNS for getting the IP and then getting connection refused instead. On the other hand, maybe I can live with .space.se being passed to teh proxy server as long as I can connect to my outer webserver. I then tried this: ======================================================= function FindProxyForURL(url, host) { if (localHostOrDomainIs(host, "www.space.se")) return "PROXY wwwgate:3128"; if (localHostOrDomainIs(host, "outer.space.se")) return "PROXY wwwgate:3128"; if (localHostOrDomainIs(host, "www")) return "PROXY wwwgate:3128"; if (localHostOrDomainIs(host, "outer")) return "PROXY wwwgate:3128"; if (isPlainHostName(host)) return "DIRECT"; return "PROXY wwwgate.space.se:3128"; } Using this, I get: ntweb - proxy connect ntweb.space.se - Proxy connect unixweb - Proxy connect unixweb.space.se - Proxy connect www - Proxy connect www.space.se - Proxy connect big.bad.int - Proxy connect Ooops, not really what I wanted. Just broke the application based on ActiveX. Wonder why. ====================================== Ugly hack # 1 function FindProxyForURL(url, host) { if (isPlainHostName(host) && !localHostOrDomainIs(host, "www.space.se") && !localHostOrDomainIs(host, "outer.space.se")) return "DIRECT"; else if (dnsDomainIs(host, ".space.se") && !localHostOrDomainIs(host, "www.space.se") && !localHostOrDomainIs(host, "outer.space.se")) return "DIRECT"; else return "PROXY wwwgate.space.se:3128"; } Using this, I get: ntweb - proxy connect ntweb.space.se - Connect direct unixweb - Proxy connect unixweb.space.se - Connect direct www - Proxy connect www.space.se - Proxy connect big.bad.int - Proxy connect Not exactly what I had expected. That's it. I am at wits end here. ANyone care to come up with a solution that works as advertised ?? Tommy