Robert Schetterer wrote:
Geert Hendrickx schrieb:
On Tue, Oct 20, 2009 at 02:04:15PM +0500, rihad wrote:
"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?

You could replace the virtual(8) delivery agent by a program of your own,
by adding an entry in master.cf and pointing "virtual_transport" to it.

http://www.postfix.org/postconf.5.html#virtual_transport
http://www.postfix.org/master.5.html


        Geert



maildrop has good possibilities to exec external progs

If I understood Wietse correctly, You MUST use one of Postfix's deliver programs in master.cf:

local, virtual, pipe, smtp.

as the interface to the queue manager is not published and is subject
to change without notice.

I might as well write my own thin wrapper for virtual and be done:

#!/bin/sh
# do not read the body, but do my own actions based on RCPT TO
...
# and finally...
exec /path/to/postfix/virtual $@

and change in master.cf:
virtual unix - n n - - /path/to/my/virtual-wrapper

Reply via email to