المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : How to Disable a Domain From Sending Email



Rise Company
05-11-2014, 20:49
How to Disable a Domain From Sending Email You can easily disable inbound email for a single domain simply by switching off the MX records and/or removing the domain from /etc/localdomains. However, disabling a domain from sending email off of your server is slightly more complicated. Even if you manage to disable the domain of an account from sending out, you still have to deal with the fact that the cPanel user itself can send email. This user has the address of user@serverhostname, and is the default sender for scripts that utilize sendmail. In other words, any PHP or Perl script that sends email off of your server without using proper SMTP authentication will send mail as the cPanel user.
Disable Email from Specific Domains First, create a file called /etc/blockedsenderdomains, and add the list of domains to block email from to this file, one line at a time.
Then go into WHM > Exim Configuration Manager > Advanced Editor, and add the following to “Section: CONFIG” part:

domainlist blocked_domains = lsearch;/etc/blockedsenderdomains In the ROUTERSTART section, add:


reject_domains:
driver = redirect
domains = +blocked_domains
allow_fail
data = :fail: Connection rejected: SPAM source $domain is manually blacklisted.
Then save the file.
http://cpanelservermanagement.com/2014/04/28/how-to-disable-a-domain-from-sending-email/