Using Spamd rather than the SpamAssassin Library

Matt Hampton spamlists at
Fri Sep 5 21:18:39 IST 2008


Don't know if anyone is interested but I have a (heavily) modified  which allows MailScanner to use spamd rather than the 
Mail::SpamAssassin library (similiar to how Rick(?) implemented the 
calmd vs ClamAVModule).  I have checked with Jules and he is happy with 
me sharing it.

$Id: 4522 2008-08-20 15:19:23Z sysjkf $


Once this patch is in place MailScanner relies solely on spamd - you 
cannot choose between the two.
This is beta code and it uses a file from the SVN repository of 
SpamAssassin which hasn't be published yet!


take a backup of the files

in the MailScanner installation (on mine /usr/lib/MailScanner/MailScanner)

copy the downloaded file over the top of the existing file
add the following three lines to the bottom

spamduser <USER>

(where <USER> is the default user for spamd)

The defaults  for spamdserv/spamdport are "localhost" and port 783

YOU MUST REPLACE <USER> with a valid user!

Locate you

Over write this with 

This is a drop in replacement and does not change the functionality - it 
exposes some extra bits and pieces.

Why would you want to do this?

Memory - Small over head as the SpamAssassin rules are loaded in to 
shared memory
Faster - in theory it should be faster - haven't noticed a difference

The biggy.....:  If you were to put in your MailScanner.conf file

Spamd User = &SomeFunction

You can now control the user that talks to the spamd.

This gives you:
Individual bayes
Individual awl
Individual scores

Need I say more.....

enjoy and feed back please.  If enough people like it (especially 
Jules!), I believe that  retaining the ability to chose between the two 
is possible.


More information about the MailScanner mailing list