Robin McCorkell: > Hi, > > I'm setting up an MTA, and as part of the spam filtering process I'm > using SpamAssassin via amavisd-new. However, this is running on a small > box, with little CPU, so I also use postscreen to filter most messages > before the expensive heuristics run. > > Currently, I run DNSBL checks in postscreen and SpamAssassin, first to > filter most spam and then again in SpamAssassin to augment the score and > make a better filtering decision. This is quite wasteful, so I was > wondering if there is some way to get the DNSBL score from postscreen > into a header or something (like PREPEND in a CIDR table fired by > check_client_access or similar test), so that SpamAssassin can just read > that header without having to do the checks itself. > > If this currently isn't possible, I'd be happy to make a crack at > implementing it myself, assuming this is something that would be > considered useful by others.
It's not as wasteful as you might think; the answers are still cached in the DNS server. The postscreen daemon does not receive mail and consequently does not modify message content. It can, however, pass along some data as it hands off a connection to a Postfix SMTP daemon process. See psc_send_socket() for how to send, and smtpd_peer_from_pass_attr() for how to receive. Wietse