Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

MX entries for subdomains...

Discussion in 'General Discussion' started by 4u123, Mar 12, 2008.

  1. 4u123

    4u123 Well-Known Member PartnerNOC

    Jan 2, 2006
    Likes Received:
    Trophy Points:
    We are using an external anti spam appliance to handle mail for all our customers domains. In order to do this we changed the MX records for all local domains on the cpanel server to the hostname of our anti spam box. The anti spam server then receives mail on behalf of the domains, ditches the spam messages and sends on the legitimate mail to the cpanel servers. This has been working great so far.

    In order to successfully acheive this, there are a couple of things that must be set up...

    1. Domains must be set to allow mail to be delivered locally - this is how the anti spam server is able to send on the messages. In other words, although the MX has been changed - the domain remains in localdomains and is not added to remotedomains.

    2. Incoming SMTP connections must be restricted (via an acl) to allow only the anti spam server and authenticated users to connect to the cpanel server - otherwise, anyone could still send spam directly to a domain on the server and it would be accepted.

    This works perfectly for all domains hosted on the server. It controls the route that mail takes into the server so that all incoming mail is directed through the anti spam appliance first - all other SMTP connections apart from authenticated users sending mail out from the server are rejected. Its great and we are very pleased with the way it is going.

    There is however, one snag.....

    Sub domains dont have MX records by default - so if someone sends mail to a subdomain on any of our servers, it is being rejected. We need to find a way of allowing mail to be delivered into the server for subdomains - or find a way of creating an MX record automatically whenver a sub domain is created.

    Could the DNS templates be used to do this ?

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice