Sad Clouds via Postfix-users:
> # cat smtpd_sender_login_maps
> [email protected] [email protected]
>
> Only mail from support@ with user marco is allowed, all other users are
> rejected, as they are not listed in the smtpd_sender_login_maps.
>
> I would like to avoid duplicating all of the Dovecot userdb users in
> the above table and I would prefer to use smtpd_sender_login_maps as an
> exceptions table, i.e.:
>
> If authenticated user is sending mail as himself or herself then allow,
> otherwise check smtpd_sender_login_maps and if not listed then reject.
>
> Is there a way to configure Postfix like this?
It's called smtpd_sender_login_maps i.e. the plural form.
This means you can do:
/path/to/main.cf:
smtpd_sender_login_maps =
pcre:/path/to/this hash:/path/to/that
/path/to/this:
# Requires that login name equals the non-plussed sender address
/^([^+@]+)(\+[^@]*)?(@.+)$/ $1$3
/path/to/that:
[email protected] [email protected], [email protected]
See also smtpd_sender_login_maps documentation for
enforcing that header.from equals envelope.from
Wietse
_______________________________________________
Postfix-users mailing list -- [email protected]
To unsubscribe send an email to [email protected]