-----Original Message----- From: jma...@gmail.com [mailto:jma...@gmail.com] On Behalf Of Justin Mason Sent: zaterdag 16 mei 2009 10:21 To: Mark Cc: Spamassassin Mailing List Subject: Re: An SMTP transaction, SpamAssassin interface
On Sat, May 16, 2009 at 01:36, Mark <ad...@asarian-host.net> wrote: > -----Original Message----- > From: Mike Cardwell [mailto:spamassassin-us...@lists.grepular.com] > Sent: vrijdag 15 mei 2009 11:44 > To: Spamassassin Mailing List > Subject: An SMTP transaction, SpamAssassin interface > >> I know this would be a massive job, would be resource hungry, and >> would also require the co-operation of mta developers to update their >> mail servers with this interface so I'm not expecting it to happen. > > > It's not that bleak, really. No changes would have to be made to ANY > > up-to-date MTA: a simple milter could gather all information you want, > > and write it to, say, a BerkeleyDB database. SA could then simply pick > > up the info from the database. In fact, I do something similar on my > > own server. I have a milter (socketmap, actually) which gathers > > pertinent info and stores the hash of data, via BerkeleyDB, per > > connection-id. In a custom-rolled SA plugin, I then just retrieve the > > array of info for the current message, and apply scores accordingly. > > Of course, I'm not doing the same things you want, but the > > implementation idea is fairly simple, really. > there's a much simpler way -- just record the info in synthetic headers, > either in the Received hdr the MTA generates, or it additional > X- headers alongside, and place those headers in the message that SA > processes. SA rules can then read those hdrs and act on them. > no additional database required. But that approached WOULD require a change to the MTA -- which is what the OP prompted (correctly, IMHO) to say that such cooperation by MTA-builders is unlikely. You can't just tell your MTA to add extra headers (at least not in sendmail; even though you muck around a bit with sendmail.cf and have it construct something based on a few macros here and there, but it's rather limited). The beauty of milters is that support for them is already built in (when compiled in, of course); so someone would just have to write a third-party milter + SA pugin to make this work. - Mark