The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Using my cPanel server as an anti-spam gateway

Discussion in 'General Discussion' started by DReade83, Jul 15, 2007.

  1. DReade83

    DReade83 Well-Known Member

    Joined:
    Oct 20, 2006
    Messages:
    196
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Cheshire, UK
    Currently I have my cPanel server setup so that any emails that come in are directed to the 1st MX record.

    Should the 1st MX record (my client's Microsoft Exchange server) be unavailable, the email will be sent to the 2nd MX record, my cPanel server, where Exim will store the email for up to 5 days, and attempt to re-submit to the 1st MX record every 15 minutes.

    This solution works pretty well.

    What I am interested in doing is treating the cPanel server as the 1st MX record and the Exchange server as the 2nd. The idea being the cPanel server running MailScanner and ClamAV would scan incoming email, quarantine bad emails and emails that cannot be sent to the Exchange server and forward good emails to the Exchange server.

    Does anyone know if this is possible?

    Another thing is the server is a VPS, running 384MB RAM. Does this spec seem OK, or is an upgrade in order?
     
  2. nyjimbo

    nyjimbo Well-Known Member

    Joined:
    Jan 25, 2003
    Messages:
    1,125
    Likes Received:
    0
    Trophy Points:
    36
    Location:
    New York
    Well, from my own painful experience you will find that many spammers use techniques to avoid the first MX record when more than one is found. Some dont even talk to the MX record but try to talk to the IP address of the domain name itself.

    So your idea sounds good but if you implement it don't be suprised to find spammers talking to all of your mx records or skipping the first or last in attempt to avoid things like "fake" mx records or filters like yours.
     
  3. nickp666

    nickp666 Well-Known Member

    Joined:
    Jan 28, 2005
    Messages:
    770
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    /dev/null
    its perfectly possible to do (The company I work for does it) you need to use exim smartrouters - http://www.carbonstudios.co.uk/site/44/183.html

    I had a bit of trouble with a VPS with a low RAM allocation - SA is a bitch for memory usage so its probably worth upgrading before you start.
     
  4. DReade83

    DReade83 Well-Known Member

    Joined:
    Oct 20, 2006
    Messages:
    196
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Cheshire, UK
    So basically what you're saying is there's no need for having more than 1 MX record, and that you simply have the MX pointing at the Exim, which will filter out spam/viruses and then route good email to the correct mail host? Effectively meaning no spam/viruses can use the second MX (the client's server) because there isn't one.

    Is that right?
     
  5. nickp666

    nickp666 Well-Known Member

    Joined:
    Jan 28, 2005
    Messages:
    770
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    /dev/null
    basically yeah, although doesnt provide much failover that way, with the exchange server on the mx chain youre covered if either server is down - although if you have more than one server set them both up like that and then set them as the primary and secondary mx, that way the redundancy is still there (thats the way my company operates)
     
Loading...

Share This Page