Hi Wietse,
thanks a lot for your help.
One last question: in order to redirect mail from the original recipient(s) to
the catch-all address I'm using address rewriting with canonical maps. Is this
the best way to do it? Or should I rely on virtual aliasing for some reason?
My configuration:
/etc/postfix/main.cf
...
recipient_canonical_classes = envelope_recipient
recipient_canonical_maps = regexp:/etc/postfix/recipient_canonical
…
/etc/postfix/recipient_canonical
/.+@.+/ [email protected]
Thanks again,
Fabio
Il giorno 09/feb/2012, alle ore 19:31, Wietse Venema ha scritto:
> Fabio Sangiovanni:
>> Hi,
>>
>> I need to configure Postfix to get the following result: I need
>> every mail submitted by users to be redirected to a remote account
>> (via SMTP or LMTP), and every message must contain an header with
>> the original envelope rcpt. Example:
>
> /etc/postfix/main.cf
> smtpd_recipient_restrictions =
> check_recipient_access pcre:/etc/postfix/prepend.pcre
> ...stuff...
> reject_unauth_destination
> ...more stuff...
>
> /etc/postfix/prepend.pcre:
> /(.+)/ prepend X-Recipient: $1
>
> Wietse
>