On Wed, 2003-02-12 at 11:36, Nico Erfurth wrote:
> Konrad Michels wrote:
> > Hi Nico
> > In reply to your "PS" at the bottom of the mail, you get the two lists
> > from http://www.spews.org/spews_list_level1.txt and
> > http://www.spews.org/spews_list_level2.txt. Its quite interesting to
> > read on http://www.spews.org what its all about in detail.
> >
> > Once you get the lists, what I did was
> >
> > cat spews_list_level2.txt | awk '{print $1}' | grep -v "#" >>
> > spews_list2
> >
> > which produces a list of ranged ip addresses in a flat file!
> >
> > Does this make sense?
>
> Yes, but .... you should keep the block-information, so a user can see
> why he's blocked.
>
> If you are interested, I've a small script here (somehwhere) that
> normalizes such lists to one single netmask, so an entry can be found
> with a single-lookup, and you don't have to maintain a list of possible
> net*- lookups.
>
Sounds interesting - send away!
I'd still be interested in doing it on mysql - even if its just for the
academic exercise!
> btw, wouldn't be
>
> grep -v '#' spews_list_level2.txt | cut -d" " -f1 >>spews_list2
>
> easier ;)
>
Different ways of skinning the same cat! I prefer using awk because of
its versatility!
> Nico
--
***********************************************************************
*
* Konrad Michels
* System Administrator
* Surfkitchen Limited
* Abbey House
* 1650 Arlington Business Park
* Theale
* RG7 4SA
* United Kingdom
* Tel: +44 118 929 8079
*
***********************************************************************