On Fri, 2013-06-21 at 10:27 +0200, Fabio Sangiovanni wrote: > Hi everybody, > > I've configured my MSA (Postfix) so that a copy of submitted mail is > sent (BCC'd) to a postfix/amavisd-new/spamassassin system for > out-of-band antispam analysis. > The MSA is set to write envelope from/rcpt addresses in custom headers. > Is it possibile to check this addresses' domains against uridns lists? I > necessarily need to do this on the out-of-band system, I can't do it on > the system that receives mail in the first place. > Any suggestions are greatly appreciated. > Assuming that the copy is sent to a maildir format mailbox you can periodically run a shell script something this:
for m in maildir/* do spamc <$m | rescanned_results_filter mv $m scanned_dir done This could be a second pass through your normal SA system or could equally be using a differently configured copy of spamd. So, rescanning the BCCed messages is rather easy. This is basically how I run new and revised rules against my spam collection. The more important questions concern what you want to do with the BCCed mail after its second scan and what you'll do with the results scanning it the second time. Martin