[imp] imp and spamassassin

Nico Weinreich webmaster at posingcrew.de
Sun Nov 18 14:26:27 UTC 2007


Hi there,

with imp it's possible to train spamassassins bayes filter with imp. In 
my imp-conf I've the following options

$conf['spam']['program'] = '/usr/bin/sa-learn -u amavis 
--prefspath=/etc/spamassassin/local.cf 
--siteconfigpath=/etc/spamassassin --spam';
#$conf['spam']['program'] = '/usr/bin/spamc -L spam -s 102400 -u amavis ';
$conf['spam']['reporting'] = true;
$conf['notspam']['program'] = '/usr/bin/sa-learn -u amavis 
--prefspath=/etc/spamassassin/local.cf 
--siteconfigpath=/etc/spamassassin --ham';
#$conf['notspam']['program'] = '/usr/bin/spamc -L ham -s 102400 -u amavis ';
$conf['notspam']['reporting'] = true;

Because I'm not using spamd so I cannot use the spamc command. Training 
is fine, but there is a problem when learning from large files. When 
there is a message with a size about 3 or 4 MB, the bayes_toks DB grows 
and grows and grows sometimes 10 or 20 MB, so older tokens are lost by 
expire. In /imp/lib/Spam.php I can see, that the message is piped to the 
sa-learn as raw message. Is there an option to define a maximum size for 
a file, which can be submitted to sa-learn? This would be very important 
for me.

Greetz, Nico



More information about the imp mailing list