On Thu, May 18, 2023 at 07:07:55PM -0400, Alex via Postfix-users wrote: > > Is there a way to control smtpd_recipient_restrictions on a per-domain > > > basis [...]
To resolve the ambiguity, you might have said: "per *recipient* domain" > If I interpret your instructions properly, this is kind of an as-needed > fqdn bypass, when what I'm trying to do is allow non-fqdn senders just for > certain recipient domains. This time it is more clear: main.cf: pcre = pcre:${config_directory}/ smtpd_recipient_restrictions = reject_unauth_destination, check_recipient_access ${pcre}rcpt-checks.pcre ... rcpt-checks: /@example\.com$/ DUNNO /@example\.org$/ DUNNO /^/ reject_unknown_sender_domain Unfortunately, we don't yet have a non-regexp map type that has a default result. This could be a variant of unionmap that takes the first matching value instead of combining all values: firstmatch:{ type1:name1, type2:name2, ..., static:{ default } } With that, it'd be: main.cf: indexed = ${default_database_type}:${config_directory}/ smtpd_recipient_restrictions = reject_unauth_destination, check_recipient_access firstmatch:{ ${indexed}rusd-optout, static:reject_unknown_sender_domain } ... rusd-optout: example.com DUNNO example.org DUNNO -- Viktor. _______________________________________________ Postfix-users mailing list -- postfix-users@postfix.org To unsubscribe send an email to postfix-users-le...@postfix.org