Restricting Incoming Mail To Trusted Hosts

LukeQMT

Member
May 6, 2014
7
0
1
cPanel Access Level
Root Administrator
Good morning, guys.

I apologise in advance if this particular query has been answered previously. I've taken a look through the forum and have found information that relates to the change that I'm required to make but, ideally, I'd like a bit more information to clarify what I can and should be doing to complete this task. If anyone is able to provide me with a better understanding and/or a solution, I'd be hugely grateful!

I had never used cPanel/WHM before taking on my current role as a network & systems administrator and so I must apologise in advance once again... this time for my ignorance and lack of knowledge regarding the software!

We currently host two separate domains on our VPS. I've recently implemented a cloud-based spam filter that is dealing with incoming mail for only one of the two domains. It's working very well for us so far, although it's become apparent to me that some spammers are bypassing the primary MX entries and contacting the server directly. I'd like to stop incoming mail to the spam-filter enabled domain from receiving any mail unless it comes specifically from the filter itself. Is there a way to do this without compromising the inbound mail connectivity for the second domain (which isn't monitored/filtered by the cloud-based service)?

Hopefully my request makes at least a small amount of sense..!

Thanks in advance, folks.

Luke.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,258
463
Hello :)

You may find the following option within cPanel for this account helpful:

Account Level Filtering

If the message header contains certain information noting the additional SPAM filtering, then you could use it to create an account level filter which rejects messages that do not include that information.

Thank you.
 

LukeQMT

Member
May 6, 2014
7
0
1
cPanel Access Level
Root Administrator
Thank you for answering my query, Michael. Much appreciated! In order to get cPanel to accept mail from the spam filter and nowhere else would I be right in configuring the filter like this..?

Any header equals spam.filterA.net

OR

Any header equals spam.filterB.net

If that's correct will that cause any problems with mail that originates on the server itself? We host a website from which we receive lots of user-completed forms on a daily basis. Does the account level filtering apply to these e-mails or is it only for mail originating from outside the IP of the server?

Thanks again for your assistance!

Luke.