Re: [squid-users] Hostname ACL question

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Fri, 18 Mar 2005 17:26:43 +0100 (CET)

On Wed, 16 Mar 2005, Joe Giles wrote:

> I am trying to block/allow sites based on machine hostnames within my
> network; I have an inhouse DNS server that manages hostnames to IPs.

If you want to match client hostnames then the DNS must also have IP to
hostname mappings (in-addr.arpa zone).

> When I look at the squid logs, it appears to only show IP address.

To log the client hostname you need to set "log_fqdn on".

> Is there a
> way to set up a client hostname ACL based on local machines on my network.
>
> acl test srcdomain linuxbox.wolfhome.com
> acl TestACL url_regex -i <reg expression>
>
> http_access deny TestACL !test

This looks good to me. But requires that your DNS can answer the question
what is the host name of 10.100.125.47

Verify this with

    host 10.100.125.47
or
    dig 47.125.100.10.in-addr.arpa PTR

Regards
Henrik
Received on Fri Mar 18 2005 - 09:26:47 MST

This archive was generated by hypermail pre-2.1.9 : Fri Apr 01 2005 - 12:00:02 MST