RE: [squid-users] Squid + WPAD issues

From: Andrew Loughnan <andrewl@dont-contact.us>
Date: Wed, 6 Jun 2007 11:05:17 +1000

Hi Terry

isInNet refers to the network that the Host is on so where you have
(isInNet(host,"192.168.0.0","255.255.0.0")) return "PROXY
192.168.10.14:3128";

If they are GOING to a www host that is at 192.168.1.1 then it will use
the proxy 192.168.10.14:3128 this options does not refer to the clients
options

You could try using a DHCP option for each Subnet which allows you to
specify the proxy.pac -> symlink to wpad.dat file to use

Add option 252 to Predefined options

Detect proxy server using DHCPINFORM (Option2)
DHCP server can send DHCPINFORM message and then client can get
javascript URL. DHCP server should be supported using DHCPINFORM.
Windows 2000 Server/Windows .NET Server support it.
Open DHCP Window, right click the host name and select "Set Predefined
Options..."

Click "Add" button at "Predefined Option and Values" window. And then
type as below. You can give any name, but data type and Code should be
"String" and "252"

Add "AUTO-PROXY-CONFIG" to each scope options and the value should point
your proxy.pac file (make link to wpad.dat or copy same file to
proxy.pac)

http://www.grape-info.com/doc/win2000srv/internet-gw/wpad/

Hope this helps

Thanks
Andrew Loughnan
Computer Services Manager
                 
compassion innovation integrity
St Joseph's College Geelong
135 Aphrasia Street Newtown Vic 3220
T +61 3 5226 8165, F +61 3 5221 6983, E andrewl@sjc.vic.edu.au
www.sjc.vic.edu.au
 

-----Original Message-----
From: Terry Dobbs [mailto:tdobbs@associatedbrands.com]
Sent: Wednesday, 6 June 2007 1:40 AM
To: squid-users@squid-cache.org
Subject: [squid-users] Squid + WPAD issues

Hi All,

We have been using a proxy server with a WPAD.dat file for a year or
two. Now, we have setup another squid server in a remote site. I need to
configure the WPAD.dat file in a way where if you are on subnet A use
Proxy Server A and if you are on subnet B user proxy server B.

For the life of me, I cannot get this to work. For example, I am using
what is seen below, and it seems the only line that works is the "else"
statement so everyone is using the same server....?

function FindProxyForURL(url, host)
{
if (isPlainHostName(host))
return "DIRECT";
else if (isInNet(host,"192.168.0.0","255.255.0.0"))
return "PROXY 192.168.10.14:3128";
else if (isInNet(host,"192.150.170.0","255.255.255.0"))
return "PROXY 192.150.170.120:3128";
else
return "PROXY 192.150.170.120:3128";
}

Any help would be GREATLY appreciated!! All machines run IE 6 or 7 and
are on Win2K/WinXP.

Thanks
Received on Tue Jun 05 2007 - 19:05:56 MDT

This archive was generated by hypermail pre-2.1.9 : Sun Jul 01 2007 - 12:00:04 MDT