On Wed, Jun 24, 2009 at 4:33 AM, Rod Whitworth<glis...@witworx.com> wrote: > On Wed, 24 Jun 2009 07:57:16 -0300, Jose Fragoso wrote: > >>Hi, >> >>Actually, it is still there. But the format has changed >>and spamd is not being able to handle it because the IP >>address is now in the second column, like in: >> >>2009-06-24T12:28+0200 117.199.144.132 >> >>So, for the time being, the best thing to do is to use >>wrapper script. >> >>Regards, >> > > Yep. > Some time ago I ran into probs using the okean lists and I recently was > bitten by this one. > > My solution was/is to set up spamd.conf to find those data by using the > 'file method'. > I do this because a failed fetch leaves the relevant filter without > data. > > So I have cronjobs to fetch the data and format it if necessary, as in: > 26 B B B 14 B B B * B B B * B B B * B B B /root/bin/okean > that only needs to be updated once a day as it is slow to change. > and: > 31 B B B * B B B * B B B * B B B * B B B /root/bin/nixpix > so that: > 37 B B B * B B B * B B B * B B B * B B B /usr/libexec/spamd-setup > works properly. > > okean: > #!/bin/sh > ftp -o /var/db/china.txt http://www.okean.com/chinacidr.txt > ftp -o /var/db/korea.txt http://www.okean.com/koreacidr.txt > > nixpix: > #!/bin/sh > cd /root/data > rm -f nixspam > /usr/local/bin/wget -q www.openbsd.org/spamd/nixspam.gz > if [ $? -eq 0 ] ; then > B B B B gunzip nixspam.gz > B B B B cut -d " " -f 2 nixspam >/var/db/nixspam > fi > exit > > spamd.conf points at the outputs of those scripts. > > If any of those fetches fails, the previous data is still in place to > maintain spamd when it runs each hour.
Umm... you are explicitly doing and 'rm -f nixspam' in your script before wget. --patrick