[pfx] Re: reject_sender_login_mismatch question

Sad Clouds via Postfix-users <[email protected]>
Newsgroups gmane.mail.postfix.user
Message-ID <[email protected]>
On Thu, 26 Mar 2026 15:26:28 -0400 (EDT)
Wietse Venema via Postfix-users <[email protected]> wrote:

> 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]

That is exactly what I was using, minus the pcre in your example.
I followed example at https://www.postfix.org/SASL_README.html and
section "Envelope sender address authorization"

Thanks for the pcre example, this seems to be compatible with regexp,
as my Postfix install does not support pcre:

smtpd_sender_login_maps =
        regexp:/etc/postfix/smtpd_sender_login_maps.regexp
        hash:/etc/postfix/smtpd_sender_login_maps

# cat /etc/postfix/smtpd_sender_login_maps.regexp 
/^([^+@]+)(\+[^@]*)?(@.+)$/ $1$3

# cat /etc/postfix/smtpd_sender_login_maps
[email protected] [email protected]

However adding the regexp results in mail from support@ rejected when
sent by marco@:

<mail.info>Mar 26 21:10:06 vmsrv-qconix-node1 postfix/submission/smtpd[1449]: connect from rp4-8g.home.lan[10.0.0.6]
<mail.info>Mar 26 21:10:06 vmsrv-qconix-node1 postfix/submission/smtpd[1449]: NOQUEUE: reject: RCPT from rp4-8g.home.lan[10.0.0.6]: 553 5.7.1 <[email protected]>: Sender address rejected: not owned by user [email protected]; from=<[email protected]> to=<[email protected]> proto=ESMTP helo=<rp4-8g.home.lan>

It feels as if some of the maps are not working properly when used with
reject_sender_login_mismatch. May be I need to do unionmap?

https://serverfault.com/questions/948362/postfix-multiple-smtpd-sender-login-maps
_______________________________________________
Postfix-users mailing list -- [email protected]
To unsubscribe send an email to [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.