On Fri, Jul 09, 2021 at 07:34:36PM -0400, post...@ptld.com wrote: > End goal is to have different smtpd_*_restrictions per recipient. > I see restriction classes might solve this. > Can you supply more than one class in the access table? > > smtpd_restriction_classes = permissive, restrictive1, restrictive2, > restrictive3 > permissive = permit > restrictive1 = reject_unknown_sender_domain > restrictive2 = reject_unknown_client_hostname > restrictive3 = reject_unknown_helo_hostname
You don't need restriction classes for these specific cases, they can be used directly: /etc/postfix/recipient_access: joe@my.domain permit jane@my.domain reject_unknown_sender_domain, reject_unknown_client_hostname, reject_unknown_helo_hostname Restriction classes are needed once restrictions make use of external lookup tables, policy services, ... that require open connections prior to restriction evaluation. You can of course use them as aliases for lists of the simple built-in primitives above, but this is not required. > smtpd_recipient_restrictions = > check_recipient_access hash:/etc/postfix/recipient_access > > /etc/postfix/recipient_access: > joe@my.domain permissive > jane@my.domain restrictive1 restrictive2 restrictive3 Yes, you can use a list of built-in non-table primitives and/or restriction classes. -- Viiktor.