max:
> Let me try to describe what we try to achieve.
> 
> We want to intercept e-mail from the different servers (preferably in
> separated mail boxes), do some content inspection and send them out again at
> a later time.
> 
> We'd use java mail to do the content inspection, strip CC en BCC en use
> X-Original-To header to re-injecting it into postfix. 
> 
> What would be a better solution? We'd consider filters, but that doesn't
> solve the scheduling.

You can combine the Postfix content filter mechanism with the 'hold'
action.  For example:

    /etc/postfix/master.cf:
        smtp .. .. .. .. smtpd
            -o smtpd_client_restrictions=static:hold
            -o content_filter=foo:bar

(note: no space around the '=').

See FILTER_README for content filter options.

Issue the 'postsuper -H' command to release a message and have its
content inspected.

You can programmatically inspect the queue with "postqueue -j" (JSON
output, available with Postfix 3.1 and later) or "postqueue -p"
(roll your own parser).

        Wietse

Reply via email to