[squid-users] ACL Hell

From: <Graham_Trigge@dont-contact.us>
Date: Fri, 14 Oct 2005 12:27:55 +1000

Help required (before I lose all my hair),
 
I have a Squid server configured (2.5 stable 11) to redirect page
requests for a certain domain to another squid server (for security
reasons within our network):
 
cache_peer 1.2.3.4 (blah blah blah)
acl domain_name dstdomain abc.net.au
cache_peer_access 1.2.3.4 allow domain_name
 
I have now been asked to redirect certain pages in this domain (for
example, http://target.abc.net.au) to another squid server (for security
reasons). So I have configured the following acl:
 
cache_peer 5.6.7.8 (blah blah blah)
acl new_target url_regex ^http://target\.abc\.net\.au
 
For the life of me I cannot get this working. I have the following
configured in the conf file:
 
cache_peer_access 5.6.7.8 allow new_target
cache_peer_access 5.6.7.8 deny domain_name
cache_peer_access 1.2.3.4 deny new_target
cache_peer_access 1.2.3.4 allow domain_name
 
To me, this should send the target.abc.net.au through to 5.6.7.8, and send

all other abc.net.au requests through to 1.2.3.4. Either the new ACL is
not working, or the target.abc.net.au is being associated to both ACL's,
so not performing the redirection. I am either seeing no traffic get
through to either squid servers, or it is not going to the squid server I
need it to go to.
 
Questions (which I can't find answers for):
    - can an acl element cover more than one target, or is the first match

hit the only match (for example, does "target.abc.net.au" fall under both
the domain_name and new_target example above)?
    - is there a better way of configuring the acl for target.abc.net.au?
    - has anyone done this/seen this done and has examples?
 
I have been pulling my hair out for the last few days, so any help would
be grateful

Regards
 
Graham Trigge.
Received on Thu Oct 13 2005 - 20:23:34 MDT

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