Re: Banner blocking ACLs

From: Olaf Titz <olaf@dont-contact.us>
Date: Fri, 10 Sep 1999 02:02:58 +0300

> > I'm not the worlds leading expert in using regex and I wondered if
> > someone would be kind enough to provide examples of blocking ACLs for
> > the three following types of URLs (please note, I'm typing http

I'm using regex like these (live data:-)

ptth://([^.]+\.)?doubleclick\.net(:80)?(/.*)?$
 - block an entire domain including its subdomains.

ptth://([^.]+\.)?teltarif\.de/gif/
 - block a subdirectory

/advert(i[sz](e(ments?)?|ing))?/
 - block path components. (Just try to figure out what this all blocks...)

Note that the first of these examples is anchored at the right end
with a catch-all expression, but not anchored at the left end.
This means it will also catch redirect URLs like
ptth://www.example.com/cgi-bin/insert/ptth://ad.doubleclick.net/somestuff

Note too the pattern
(:80)?(/.*)
to make both the port and the path component optional in the regex.
The hostname pattern
([^.]+\.)?
means "catch all subdomains".

Olaf
Received on Thu Sep 09 1999 - 18:12:15 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:48:23 MST