Re: [squid-users] How can I ignore 'form inputs' on a urlpath_reg ex ?

From: Michael Wray <mwray@dont-contact.us>
Date: Wed, 4 May 2005 15:37:55 -0500

On Wednesday 04 May 2005 3:18 pm, Chris Robertson wrote:
> > -----Original Message-----
> > From: shonorio@alpargatas.com.br [mailto:shonorio@alpargatas.com.br]
> > Sent: Wednesday, May 04, 2005 11:30 AM
> > To: squid-users@squid-cache.org
> > Subject: [squid-users] How can I ignore 'form inputs' on a urlpath_regex
> > ?
> >
> >
> >
> > Hi,
> >
> > I'd know if is possible to create an 'acl urlpath_regex ' that will
>
> ignore
>
> > parameters sent by GET method on an url. I'm thinking on something like
> > where squid will ignore 'www.cia.com/enroll.asp?sex=male', but will deny
> > www.sex.com.
> >
> > Thanks,
> >
> > Solli M. Honorio
>
> dstdom_regex might be something to look at.
>
> For the record, something like:
>
> ^[^?]*sex[^?]*
>
> should fit the bill(1), but would be an absolute CPU hog. Not to mention
> that you would have to do something to match other "bad" words (e.g. one
> regex for each word, or a single really long regex utilizing the "or"
> operator).
>
> Chris
>
> (1) If my logic is correct, this statement should translate to "From the
> beginning of the line, match anything but a question mark zero or more
> times, the letters s, e and x all together and anything but a question mark
> zero or more times". Not pretty, but it would do what you are asking.

You are correct in your assessment of your regex, but it unfortunately
wouldn't fit the bill most likely, as he probably wouldn't want:

searchsite.com//index.html?search=sex

Unfortunately, I don't know of any reasonably fast method for doing this
without a redirector. squidguard will do this, but again if you get too many
or too complex on your regex, it will be slow.

-- 
Michael Wray
AimConnect, an S4F Inc. Company
918.524.1010 ext 106
mwray@aimconnect.com
http://www.aimconnect.com
Received on Wed May 04 2005 - 14:38:13 MDT

This archive was generated by hypermail pre-2.1.9 : Wed Jun 01 2005 - 12:00:02 MDT