I've started setting up an email server, and it's going quite well so far, but I want to add spam filtering.
It's not a normal email server, it's more of a central storage for all of my external email accounts, so what I've got so far is: Setup one Linux user account per email account. Getmail receives the mail, and stores it in maildir format if each user's home directory. Dovecot acts as a local IMAP server to allow me to pick up the emails from each user.
What I want is a server side spam filter in there, has anyone done anything like this?
Matt
On Fri, 2007-07-27 at 15:16 +0100, mephi wrote:
What I want is a server side spam filter in there, has anyone done anything like this?
Hi Matt,
As you have probably gathered; I don't have much of a clue about Linux but if it is any help the ancient mail server I am trying to update used the old fashioned:
fetchmail -> procmail -> spamassassin -> imap
chain to retrieve emails from various ISP POP mailboxes, filter them for spam, and make them available to endusers via imap.
You can read about procmail here: http://userpages.umbc.edu/~ian/procmail.html
and spamassasin here: http://spamassassin.apache.org/
The two critical config files, in my case, are the ".procmailrc" and ".spamassassin/user_prefs" files in each users home directory.
You can take a peek at my own ".procmailrc" file by looking here: http://www.suffolk-ancestor-genealogy-research.co.uk/alug/procmailrc.txt
and you can take a peek at my own ".spamassassin/user_prefs" file by looking here: http://www.suffolk-ancestor-genealogy-research.co.uk/alug/user_prefs.txt
Bearing in mind I was told me off by various ALUGers for using Debian 3.0 on our samba server I won't mention that our mailserver is running a older version than that... so I expect there are much more modern alternatives to procmail + spamassassin these days... but this very simple combination works ok for us.
Have fun!
Sagr.
Ok, I think I've got it working like this: Getmail > Spamassassin > Dovecot(Imap)
But I need to wait for some spam to come in so I can start training Spamassassin. It's odd, I've never wanted spam before...
I think that Spamassassin just labels spam, so once I'm happy that I've got that working, I'll pull in procmail to move it to the junkmail folder.
Matt
-----Original Message----- From: sagr [mailto:alug1@suffolk-ancestor-genealogy-research.co.uk] Sent: 28 July 2007 07:13 To: mephi Cc: main@lists.alug.org.uk Subject: Re: [ALUG] Email server and spam filtering
On Fri, 2007-07-27 at 15:16 +0100, mephi wrote:
What I want is a server side spam filter in there, has anyone done
anything
like this?
Hi Matt,
As you have probably gathered; I don't have much of a clue about Linux but if it is any help the ancient mail server I am trying to update used the old fashioned:
fetchmail -> procmail -> spamassassin -> imap
chain to retrieve emails from various ISP POP mailboxes, filter them for spam, and make them available to endusers via imap.
You can read about procmail here: http://userpages.umbc.edu/~ian/procmail.html
and spamassasin here: http://spamassassin.apache.org/
The two critical config files, in my case, are the ".procmailrc" and ".spamassassin/user_prefs" files in each users home directory.
You can take a peek at my own ".procmailrc" file by looking here: http://www.suffolk-ancestor-genealogy-research.co.uk/alug/procmailrc.txt
and you can take a peek at my own ".spamassassin/user_prefs" file by looking here: http://www.suffolk-ancestor-genealogy-research.co.uk/alug/user_prefs.txt
Bearing in mind I was told me off by various ALUGers for using Debian 3.0 on our samba server I won't mention that our mailserver is running a older version than that... so I expect there are much more modern alternatives to procmail + spamassassin these days... but this very simple combination works ok for us.
Have fun!
Sagr.
On Fri, 27 Jul 2007, mephi wrote:
I've started setting up an email server, and it's going quite well so far, but I want to add spam filtering.
It's not a normal email server, it's more of a central storage for all of my external email accounts, so what I've got so far is: Setup one Linux user account per email account. Getmail receives the mail, and stores it in maildir format if each user's home directory. Dovecot acts as a local IMAP server to allow me to pick up the emails from each user.
What I want is a server side spam filter in there, has anyone done anything like this?
Matt
Hi Matt,
I use exim for handling the mail, with the help of amavis and spamassassin. amavis acts as an MTA (like sendmail or exim) and interfaces with spamassassin and the virus scanner of your choice. You can set spam filtering rules in the amavis config file.
I used to use fetchmail for getting my mail. You can configure that so that user_a@wibble.com,user_b@wibble.com maps to user@local.com. I stopped using it, as I get my mail delivered direct via SMTP now.
HTH
Chris