Restrict or block Postfix Sender address

This article describes how to configure Postfix to restrict mails from a specific sender or domain. Firstly edit your /etc/postfix/main.cf file, and add the following: smtpd_sender_restrictions = check_sender_access hash:/etc/postfix/sender_access Next create the file /etc/postfix/sender_access, below is an example: janedoe@acme.local REJECTjohndoe@acme.com OKacme.com REJECT Now you need to create a hash file: sudo…

Continue reading