On 2022-02-20 01:49, Phil Biggs wrote:
I have virtual_mailbox_maps in use with reject_unlisted
_recipent and use virtual_alias_maps to translate a
validated address into a single matching
address for the corresponding dovecot user. For example:

/usr/local/etc/postfix/vmailbox
        validu...@example.com whatever

/usr/local/etc/postfix/vuser
        validu...@example.com dovecotu...@example.com

In my case, these two tables will always match on the LHS.

Just wondering whether there any reason not to use the virtual
_alias table for both purposes?  It would make synchronisation with
the dovecot users DB just a little easier.

virtual_mailbox_maps = hash:/usr/local/etc/postfix/vuser
virtual_alias_maps = hash:/usr/local/etc/postfix/vuser

Seems to me that someone asking this is probably receiving mail for a
very small number of users and domains, and therefore, virtual(8)
mailbox delivery might not be the best choice.

http://www.postfix.org/BASIC_CONFIGURATION_README.html

local(8) delivery (to Unix system users) has many features lacking in
virtual mailbox delivery.  For example, ~.forward files and user
control of delivery of recipient_delimiter tagged mail.  I make
extensive use of this feature.

As for the question itself, keep in mind, virtual_mailbox_maps only
apply to domains in virtual_mailbox_domains, whereas virtual(5) alias
mapping is done for every address, regardless of class.  (Offer void
where taxed or prohibited, or in cases of receive_override_options
disabling address mapping.)

(Mail sent directly to dovecotu...@example.com should be rejected.)

That's actually a second question.  Two ways, basically.  You can
ensure the address does not exist in the recipient maps for your
chosen address class.  Or, you can use a check_recipient_access
restriction to reject for that address in smtpd(8).
--
  http://rob0.nodns4.us/

Reply via email to