Domain level blocking of users: Difference between revisions
No edit summary |
No edit summary |
||
Line 4: | Line 4: | ||
The same results can also be achieved using Amavis via [http://wiki.zimbra.com/index.php?title=Improving_Anti-spam_system#Implementing_Whitelist.2FBlacklist blacklisting]. | The same results can also be achieved using Amavis via [http://wiki.zimbra.com/index.php?title=Improving_Anti-spam_system#Implementing_Whitelist.2FBlacklist blacklisting]. | ||
1. Set the | 1. Set smtpd_sender_restrictions as appropriate for the version of ZCS | ||
ZCS7: | |||
zmlocalconfig -e postfix_smtpd_sender_restrictions="hash:/opt/zimbra/postfix/conf/reject" | zmlocalconfig -e postfix_smtpd_sender_restrictions="hash:/opt/zimbra/postfix/conf/reject" | ||
ZCS8: | |||
Add '''hash:/opt/zimbra/postfix/conf/reject ''' as the first line of '''/opt/zimbra/conf/zmconfigd/smtpd_sender_restrictions.cf''' | |||
2. Create file /opt/zimbra/postfix/conf/reject with the list of email addresses and domains to be rejected in the below format: | 2. Create file /opt/zimbra/postfix/conf/reject with the list of email addresses and domains to be rejected in the below format: |
Revision as of 21:48, 4 June 2013
Article Information |
---|
This article applies to the following ZCS versions. |
Below mentioned are the steps to "REJECT" an external email address from sending mail to the users of the Zimbra Domain.
The same results can also be achieved using Amavis via blacklisting.
1. Set smtpd_sender_restrictions as appropriate for the version of ZCS
ZCS7: zmlocalconfig -e postfix_smtpd_sender_restrictions="hash:/opt/zimbra/postfix/conf/reject"
ZCS8: Add hash:/opt/zimbra/postfix/conf/reject as the first line of /opt/zimbra/conf/zmconfigd/smtpd_sender_restrictions.cf
2. Create file /opt/zimbra/postfix/conf/reject with the list of email addresses and domains to be rejected in the below format:
user@domain.com REJECT domainX.com REJECT
3. postmap it and restart postfix
postmap /opt/zimbra/postfix/conf/reject zmmtactl stop && zmmtactl start
You'll be able to see the changes show up in /opt/zimbra/log/zmconfigd.log .
Reject messages will be logged in /var/log/zimbra.log ; format looks like this:
[date / hostname] postfix/smtpd[####] NOQUEUE: reject: RCPT from [remote mta]: 554 5.7.1 <senders-email@DOMAIN>: Sender address rejected: Access denied: from=<senders-email@DOMAIN> to=<local-zimbra-user@domain> proto=ESMTP helo=<remote mta>
The sender will receive a returned email declaring the rejection.