Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

force client to use proxy for port 80 only

Status
Not open for further replies.

in2it

IS-IT--Management
Apr 16, 2002
2
CA
I manage a series of windows client stations which are in a workgroup with no server. I need to find a way to force them to use the squid proxy server I have located in another domain for port 80 only.
The management still wants them to be able to use msn messenger etc., and whatever other chats they might want, be insists that i route this web traffice through the proxy which is running "Dans Gaurdian".
Is there a way to use a group policy to force the routing of only a certain port?

Thanks for your time.
Jay, In2IT
 
you could do it with a proxy.pac file ...
Code:
    function FindProxyForURL(url, host)
    {
        //We only cache http port 80
        if (url.substring(0, 5) == "http:")
        {
            var hostlen = host.length + 7; // [URL unfurl="true"]http://+host.length[/URL]
            var hostport = 0;
            var portpos = indexOf("/",hostlen);
            if (portpos == -1) portpos=url.length;
            if (url.substr(hostlen,1) == ":")
                hostport=url.substr(hostlen+1,portpos-hostlen-1)
            if (hostport == "80") return "PROXY your-squid-proxy:3128";
        }
        else return "DIRECT";
    }
 
I think you were speaking english, but am not sure.
What in the world is a pak file and where do I use it?
 
proxy.pac ...

you know that in your browser you have the option for 'automatic proxy configuration' with a URL box next to it?

well if you create a file called 'proxy.pac' on a local web server (content-type: application/x-ns-proxy-autoconfig) and put the url in the 'automatic proxy configuration' then it should work ...

maybe :)

if you use internet explorer there is also 'automatically detect setting' feature ... this takes more effort, but the proxy file is the same (but the name is different the name for autodetect is wpad.dat), however you have to set your local web server to have an alias of wpad.<domain name> i believe.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top