-1

I want to do the recipient address verification for some domains, but many domains I want to exclude from verification. These are subdomains of domains that are being verified and MySQL lookups matches these domains: Keys are the domains and values are the string reject_unverified_recipient.

I need to do MySQL exact domain verification. Can anyone help me? Thanks in advance.

1
  • What does the postfix documentation say? Mar 2, 2014 at 10:28

1 Answer 1

3

You should be able to achieve it with Postfix restriction classes

#/etc/postfix/main.cf

relay_domains = domain1.tld, sub.domain1.tld
relay_recipient_maps = 
smtpd_restriction_classes = restrictive, permissive

restrictive = reject_unverified_recipient
permissive = permit

smtpd_recipient_restrictions = 
  permit_mynetworks,
  reject_unauth_destination,
  check_recipient_access hash:/etc/postfix/verify_domains


#/etc/postfix/verify_domains
domain1.tld     restrictive
sub.domain1.tld permissive

Hash lookup table is used here. You can achieve the same using mysql lookup table also.

0

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .