Lindsay Haisley a écrit :
On Sun, 2008-12-21 at 13:25 -0800, Gordon Messmer wrote:
Lindsay Haisley wrote:
It looks as if Gordon Messmer has written a very nice Python-based API
for courierfilter and I'm going to give it a shot at the job. I'm going
to have to write a new module for it, but the documentation on it is
excellent and it shouldn't be too hard. I'm quite fond of Python as a
programming language :-)
Glad to hear it. Let me know if I can offer any advice. There are
modules for clamav and spamassassin which you can use as a base for
local customizations.
Gordon, here's a suggested patch for the spamassassin.py filter for
pythonfilter. This is perhaps just a demonstration of concept since you
would probably want to streamline the code.
Essentially, running SpamAssassin with configs in mysql (as opposed to
flat config files) adds a lot of flexibility to it and makes it more
attractive for use in the delivery phase. To this end, it's slower, but
more flexible, to run SpamAssassin twice, once from the courierfilter
facility to put a ceiling on the SA spam score accepted by Courier and
yet again during delivery to add SA headers and to encapsulate spam
inside of SA wrappers.
This patch implements a checkOnly flag for the module which,when set,
causes it to do nothing to the message, but to provide input gating
based on a comparison of rejectScore with the SA-determined spam score.
If checkOnly == False (the default) spamassassin.py works just as it
does without the patch.
Hello,
I dislike the way you want to make Spamassassin work. You want to scan
your mails twice. It's a bad idea as it's CPU intensive.
My advice would be to let this filter as it is right now. (put a bigger
score on mail you don't want to see at all later).
Then in your .maildroprc, you will juste have to scan headers to reject
mails according to user's preferences
HTH.
Jerome Blion.
------------------------------------------------------------------------------
_______________________________________________
courier-users mailing list
[email protected]
Unsubscribe: https://lists.sourceforge.net/lists/listinfo/courier-users