Re: Body only checking through spamc
On Wed, 2010-03-10 at 09:45 -0800, yongke wrote: Is there anyway to use spamc to only check the body section of an email? This is necessary when checking for emails that haven't been sent yet. This is possible provided that all your users send mail through an MTA that's under your control and that you have controls in place to prevent them sending mail by other routes. Under these conditions messages will contain a few headers which it may be worthwhile to scan, e.g.: From:has the sender been forged? To: are there addresses which mail should not be sent to? Subject: should a subject line always be present? Date:is it within, say, 5 minutes of the server's time? If your users can send messages via other routes forget it. Its not possible to scan messages that are sent directly to external MTAs. Since you haven't described your mail set-up its not possible to say more than this. Martin
Re: Body only checking through spamc
Hi Martin Thanks a lot for the reply, the emails our clients sends are under our control and under our MTA. How exactly would I do this though? What I have is just the email body in HTML from our clients, subject, to, etc, and some account information. Do I need to actually get the created final email outgoing before running spamc on it? Or can I just run spamc on the HTML body... What I have is something like this: html text text text.. /html -- View this message in context: http://old.nabble.com/Body-only-checking-through-spamc-tp27853336p27854454.html Sent from the SpamAssassin - Users mailing list archive at Nabble.com.
Re: Body only checking through spamc
On Wed, 2010-03-10 at 11:13 -0800, yongke wrote: Thanks a lot for the reply, the emails our clients sends are under our control and under our MTA. How exactly would I do this though? What I have is just the email body in HTML from our clients, subject, to, etc, and some account information. Do I need to actually get the created final email outgoing before running spamc on it? Or can I just run spamc on the HTML body... What I have is something like this: html text text text.. /html What, no plain text? That's guaranteed to add some spam points to the message when its passed to SA. You'll need to configure your MTA so mail from your users is passed to spamc before being passed to a post-processing program. This should let it be sent if its ham and re-address it to the sender if its spam, possibly as an attachment to a covering message. If you don't want to send out mail containing SA headers, the post-processing program can simply remove all headers that start with X-spam. I don't know of a program that can post-process spamc output, but if one exists I'm certain somebody else will tell you about it. Martin