Article View: news.software.readers
Article #191275[slrn] spamassassin works too (Was: [slrn] very easy display filter enabling colour in message body)
From: Troy Piggins
Date: Tue, 03 Oct 2006 23:57
Date: Tue, 03 Oct 2006 23:57
43 lines
2243 bytes
2243 bytes
* Troy Piggins wrote:
> I've been using a demime and t-prot display filter for some time
> to tidy up MIME pgp signed and html messages, and trimming long
> quote blocks, trimming overly long sigs etc. All good.
>
> I just recently started playing with my own display filter to
> take it all one step further to fix some things like improper sig
> delimiters etc using a sed script. I got that working and
> thought I'd share. It's very customisable.
Just for fun I have just tried piping the message through
spamassassin (spamc). It works!
#!/bin/bash
spamc \
| sed -e '
# fix incorrect sig delimiters
s/^--$/-- /
# put a blank line before sig delimiters if not one there
#/^-- /{g;s/^$/-- /;t;s/.*/\n-- /};h
# email addresses
s/[$a-zA-Z0-9.-]*@[a-zA-Z0-9.-]*/_&_/g
'
I can see message spam scores with this in my ~/.slrnrc:
visible_headers "From:,Subject:,Newsgroups:,Date:,Message-ID:,X-Spam-Level:"
I know spamassassin isn't for usenet, but message formats are so
similar it seems to do ok at detecting usenet spam.
[snip]
--
Troy Piggins
,-o
o ) Ubuntu linux 6.06 http://ubuntu.com RLU#415538 http://counter.li.org
`-o uptime: 09:48:37 up 2:43,2 users,load average:0.13,0.05,0.01
Technical Details
Message-ID:
<20061004094837@usenet.piggo.com>Path:
mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20140922.mbox.gz!number1.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed.iinet.net.au!newsfeed.iinet.net.au!per-qv1-newsstorage1.iinet.net.au!per-qv1-newsstorage1.iinet.net.au!per-qv1-newsreader-01.iinet.net.au!not-for-mailReferences:
<20061002123732@usenet.piggo.com>Show Full Headers
Complete Article Headers
Message-ID: <20061004094837@usenet.piggo.com> Subject: [slrn] spamassassin works too (Was: [slrn] very easy display filter enabling colour in message body) Date: Wed, 04 Oct 2006 09:57:14 +1000 From: Troy Piggins <usenet-0610@piggo.com> References: <20061002123732@usenet.piggo.com> Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20140922.mbox.gz!number1.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsfeed.iinet.net.au!newsfeed.iinet.net.au!per-qv1-newsstorage1.iinet.net.au!per-qv1-newsstorage1.iinet.net.au!per-qv1-newsreader-01.iinet.net.au!not-for-mail Newsgroups: news.software.readers Reply-To: usenet-0610@piggo.com User-Agent: slrn/0.9.8.1pl1/rt (Linux) Lines: 43 NNTP-Posting-Host: 203.206.60.205 X-Trace: 1159920002 per-qv1-newsreader-01.iinet.net.au 8390 203.206.60.205