From: Chris Martin on
I am looking for a way to process mails after spam-assassin is done with
them, and I'd like to avoid using procmail as it's memory hungry and
mailbox oriented, and not really what we're looking for. We just want to
dump all e-mails with a X-Spam header value of over 15 to a folder,
however the only actions listed in the milter-regex man page are reject,
tempfail, discard, quarantine and accept.

How hard would it be to expand the milter to add an outputdirectory
option in? Is the quarantine option useful? I understand that quarantine
option just changes a flag on the queue, can you suggest a method of
dropping all queued messages to a folder once a day, or some such?


Thanks!

Chris M
From: jmaimon@ttec.com on

Chris Martin wrote:
> I am looking for a way to process mails after spam-assassin is done with
> them, and I'd like to avoid using procmail as it's memory hungry and
> mailbox oriented, and not really what we're looking for. We just want to
> dump all e-mails with a X-Spam header value of over 15 to a folder,
> however the only actions listed in the milter-regex man page are reject,
> tempfail, discard, quarantine and accept.
>
> How hard would it be to expand the milter to add an outputdirectory
> option in? Is the quarantine option useful? I understand that quarantine
> option just changes a flag on the queue, can you suggest a method of
> dropping all queued messages to a folder once a day, or some such?
>

If you do modify it, I suggest you simply add a recipient with
smfi_addrcpt() instead of trying to deal with filesystem and security
issues.

Create an alias that spools mail to a file.

Or, why dont you use a milter like spamass-milter and use its ability
to add recipients to the email message?

From: Chris Martin on
jmaimon(a)ttec.com wrote:

>
> If you do modify it, I suggest you simply add a recipient with
> smfi_addrcpt() instead of trying to deal with filesystem and security
> issues.
>
> Create an alias that spools mail to a file.
>
> Or, why dont you use a milter like spamass-milter and use its ability
> to add recipients to the email message?
>

It never occurred to me I could achieve any of this with the default
spammass-milter. I've had a look and the -b option seems my best bet,
but it diverts all tagged mail, where as I only want to send tagged mail
with a score over a certain point. This allows us to tag from 8 to 17,
so that users get anything we're not 100% about, and the rest we can
inspect at leisure.

It's a pity that the regex milter doesn't let you redirect mails by
default. I'm not a good coder at all, so if I can avoid having to code
it up myself I'd prefer to!


Thanks for your help.
From: jmaimon@ttec.com on

Chris Martin wrote:

> I've had a look and the -b option seems my best bet, but it diverts all tagged mail, where as I only want to send tagged mail with a score over a certain point. This allows us to tag from 8 to 17, so that users get anything we're not 100% about, and the rest we can inspect at leisure.


See my bBr patch hosted at the spamass-milter savannah page or at

http://www.jmaimon.com/sendmail/spamass-milter/

From: Chris Martin on
jmaimon(a)ttec.com wrote:
> Chris Martin wrote:
>
>> I've had a look and the -b option seems my best bet, but it diverts all tagged mail, where as I only want to send tagged mail with a score over a certain point. This allows us to tag from 8 to 17, so that users get anything we're not 100% about, and the rest we can inspect at leisure.
>
>
> See my bBr patch hosted at the spamass-milter savannah page or at
>
> http://www.jmaimon.com/sendmail/spamass-milter/
>

Has this been merged into the main milter code yet? Most of the dates
seem to be from 2004.

If it hasn't been done yet, I will ask the FreeBSD ports guys to create
a new spamass-milter port (I don't have any sort of clout, so I don't
know if they will) with the patch included by default. It seems very
basic functionality that a lot of people would want, and it's a pain to
have to patch code every time it's updated, and seeing this is what
ports is for I might as well use it :)

Thanks!