Michael Shadle:
>
> > On Sep 21, 2015, at 3:19 AM, Wietse Venema <[email protected]> wrote:
> >
> > Have a look at:
> >
> > http://www.postfwd.org/
> > http://www.postfix.org/SMTPD_POLICY_README.html
>
> Another option could be using a pre-queue content filter, and
> string replace the message (or ideally just the headers) removing
> any of the non-allowed recipients with a bitbucket address, and
> let postfix handle the message after it's been tampered. Right?
I did not read the original question in detail, but recipients are
not specified in message header. Instead they are specified in
the envelope (RCPT TO commands in SMTP).
Note that SMTP sends recipients before the message header and body,
so any rejects based on content would affect all message recipients.
That is, you can't undo an "250 OK" reply to RCPT TO at a later time.
Wietse