Re: [squid-users] Access denied but no match

From: Colin Campbell <sgcccdc@dont-contact.us>
Date: Mon, 25 Mar 2002 16:39:06 +1000 (EST)

Hi,

On Mon, 25 Mar 2002, Barry Darnton wrote:

> I debugged and got the following info from the cache.log file
>
> aclCheck: checking 'http_access deny av'
> 2002/03/25 17:09:58| aclMatchAclList: checking av
> 2002/03/25 17:09:58| aclMatchAcl: checking 'acl av url_regex -i
> "/usr/local/squid/etc/av.txt"'
> 2002/03/25 17:09:58| aclMatchRegex: checking 'http://www.rad.com/'
> 2002/03/25 17:09:58| aclMatchRegex: looking for '\.avi'
> 2002/03/25 17:09:58| aclMatchRegex: looking for '\.ram?'
> 2002/03/25 17:09:58| aclMatchAclList: returning 1
> 2002/03/25 17:09:58| cbdataUnlock: 0x822dde8
> 2002/03/25 17:09:58| aclCheck: match found, returning 0
> 2002/03/25 17:09:58| aclCheckCallback: answer=0
> 2002/03/25 17:09:58| cbdataValid: 0x8bdebb0
> 2002/03/25 17:09:58| The request GET http://www.rad.com/ is DENIED, because
> it matched 'av'
> 2002/03/25 17:09:58| Access Denied: http://www.rad.com/
>
> What I cant figure out is where \.ram? matched in the url, is this a bug or
> am I the luser:-)

The latter, I'm afraid :-). Your regular expression "\.ram?" is

        \ take next character literally
        . that means a dot
        r that means "r"
        a that means "a"
        m that means "m"
        ? that means previous character is optional

In English, you are looking for a "." followed by "ra", possibly followed
by "m". Since "http://www.rad.com/" contains a "." followed by "ra" not
foolwed by the optional "m" so it matches. Why is the "?" there?

Colin
Received on Sun Mar 24 2002 - 23:39:53 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 17:07:03 MST