Re: [squid-users] Custom error pages for cache_peer_access rules

From: Amos Jeffries <squid3_at_treenet.co.nz>
Date: Thu, 22 Nov 2012 17:26:44 +1300

On 21/11/2012 2:59 p.m., Paul Ch wrote:
> Hi,
>
> Is there a way of showing custom error pages for cache_peer_access ACL's
> in a squid reverse-proxy?
>
> I have rules like:
>
> cache_peer_access test allow sites_test group1
> cache_peer_access test allow sites_test wisp
> cache_peer_access test deny sites_test publicall
>
> If someone outside of group1 and wisp tries to connect to this peer,
> they get the 'ERR_CANNOT_FORWARD' message.
> With http_access rules, I can change this using deny_info. Is there an
> equivalent for cache_peer_access?

No because cache_peer_access is not granting service permission to the
client. It is simply selecting whether or not the peer is going to be
*attempted* contact.
Only http_access, adapted_http_access, and http_reply_access are able to
replace the response object using deny_info.

For example; if you have two peers not allowed to be contacted. Which
error page would you display? what if one were allowed and one not
working? and why would you display any error page if there were a third
option which *could* be used?

Amos
Received on Thu Nov 22 2012 - 04:27:02 MST

This archive was generated by hypermail 2.2.0 : Thu Nov 22 2012 - 12:00:04 MST