Re: [squid-users] myport config

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Tue, 11 Oct 2005 16:16:21 +0200 (CEST)

On Tue, 11 Oct 2005, gembel elit wrote:

> delay pools didn't work if i use squid as transparent
> proxy, but it worked if i set proxy in browser
> setting.

The myport/myip acls by design does not work in transparent proxies.

> Is this a bug? how to make it work in squid 3.

Should work in squid 3 I think.. but maybe not. Right, it does not. To
address this fhe following needs to be fixed:

connStateCreate:

         if (clientNatLookup(fd, *me, *peer, &dst) == 0) {
             result->me = dst; /* XXX This should be moved to another field */
             result->transparent(true);
         }

prepareTransparentURL:

         /* Put the local socket IP address as the hostname. */
         int url_sz = strlen(url) + 32 + Config.appendDomainLen;
         http->uri = (char *)xcalloc(url_sz, 1);
         snprintf(http->uri, url_sz, "%s://%s:%d%s",
                  http->getConn()->port->protocol,
                  inet_ntoa(http->getConn()->me.sin_addr),
                  ntohs(http->getConn()->me.sin_port), url);
         debug(33, 5) ("TRANSPARENT REWRITE: '%s'\n", http->uri);

(both in src/client_side.cc)

Regards
Henrik
Received on Tue Oct 11 2005 - 08:16:23 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Nov 01 2005 - 12:00:04 MST