On 12/27/2013 01:13 PM, post...@pupat-ghestem.net wrote:
Hello,
I am trying to setup an email address where only mails from authorized
users (defined in a list) would come in and other emails would be
forwarded to another address.
To a single address? Local or remote ?
Are you only testing the sender address in this ?
If so, why are you accepting unauthorized senders at all?
Is the recipient is irrelevant, i.e. you want a wildcard accept policy ?
Note that the last option is a definite no-no as far as I am concerned;
you want to verify the recipient before you check for authorized senders.
I was thinking of doing this with a combination of postfix and procmail:
having postfix delivering all incoming email, then procmail forward
and delete email not coming form authorized users. Before implementing
it I was wondering if there is a postfix-only solution to this.
You could use sender_dependent_default_transport_maps: map the
authorized senders to DUNNO (thus using whatever it was going to use
before) and everything else to a custom transport that sends it wherever
you want.
http://www.postfix.org/postconf.5.html#sender_dependent_default_transport_maps
--
J.