On 2009-10-20 rihad wrote: > Geert Hendrickx wrote: >> On Tue, Oct 20, 2009 at 01:03:04PM +0500, rihad wrote: >>> Hi there, I need an external command to be run whenever new mail is >>> finally delivered to a virtual domain, but I don't need access to >>> the body of that mail, only who it is for (from its headers). Just >>> wondering if content filtering is the most efficient way supported >>> by Postfix to do that: >>> http://www.postfix.org/FILTER_README.html >> >> "Who it is for" cannot be derived from headers, only "who it appears >> to be for". You need the RCPT TO information. This is available for >> a content filter, but a policy daemon would probably be more >> efficient for your case: >> >> http://www.postfix.org/SMTPD_POLICY_README.html > > "The Postfix SMTP server has a number of built-in mechanisms to block > or accept mail at specific SMTP protocol stages." > > But the mail could later be filtered etc., so it's a bit early for the > external program to run. I want it to run only if the delivery has > been guaranteed, like as the last content filter through pipe. > Nevermind the body overhead. Possible?
Maybe I'm missing something, but I'd do this kind of thing with procmail/formail rather than in Postfix. Regards Ansgar Wiechers -- "All vulnerabilities deserve a public fear period prior to patches becoming available." --Jason Coombs on Bugtraq