Karsten Krämer wrote:
Hi,
we use postfix, amavisd-new, spamassassin on a linux box as relay,
exchange on server 2003 as final destination.
Which way is the best to get (ham and/or spam) mail out of user
mailboxes from exchange to linux for further "sa-learning".
Maybe there exist some Howto - we didn't manage to find them yet.
At the moment we collect the body texts in two big files and manually
learn spamassassin to separate the "good from the ugly", but in this way
all headers are lost.
Any more advanced ideas? Any help appreciated.
Thanks
Karsten
I use something kind of ugly, but it works.
1. I created two public folders, "should-be-spam" and "should-be-ham"
and I semi-regularly remind users to copy (for ham) or move (for spam)
mis-marked messages. The message that goes with spam includes a link to
a web page explaining how to move a mis-marked spam message to the
"should-be-spam" folder.
2. I created a user for Exchange, "sa", with access to the public folders.
3. On one of the Linux systems that run SA, I run a script at 5 minutes
after every hour, "sa-junk"
sa-junk:
--------
#! /bin/sh
rm -f /var/spool/mail/sa
fetchmail -a -K -f /root/sa-junk.fetchmailrc -r "Public
Folders/should-be-spam"
cat /var/spool/mail/sa >> /root/should-be-spam
sa-learn --spam --mbox /root/should-be-spam
rm -f /var/spool/mail/sa
fetchmail -a -K -f /root/sa-junk.fetchmailrc -r "Public
Folders/should-be-ham"
cat /var/spool/mail/sa >> /root/should-be-ham
sa-learn --ham --mbox /root/should-be-ham
sa-junk.fetchmailrc
-----------------
poll my.exchange.server with protocol imap
user sa, with password sapassword, is sa here
Periodically, I gzip the should-be-* files and move them into an archive
area.
--
Steve