On Configurable Spam Filters

Uncategorized — Антон Марчуков @ 06.04.06 16:01

Here is a basic spam score filter design for exim and sa:

1) Users can save their preferred spam score level in the database
2) After processing a message with SpamAssassin, we compare resulted spam score with the one in user’s database. That is done by DATA ACL and user is identified by RCPT SMTP command. If score matches, we add X-Spam-Flag header here, this will be a flag for both user and us later
3) In the routers section we are checking X-Spam-Flag and if we have one, we deliver to the spam folder

Pretty simple and straightforward design, but, what should I do when we have several RCPT commands per a message in SMPT session? Current implementation checks spam score only against the first RCPT and then delivers message to all of them, that’s not good, I should have moved the check to the router section, but, I dunno how to add X-Spam-Flag header there.

My head is filled with the problem, if I won’t solve it pretty, I’ll get insane.


Leave a comment


This work is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Unported License.
(c) 2017 Anton Martchukov's Weblog | powered by WordPress with Barecity