Block e-mail sender server wide

jtgroup

Active Member
Nov 21, 2017
38
3
58
UK
cPanel Access Level
Root Administrator
Hello everyone,

I would like to block some e-mail accounts from sending messages to any domains hosted on our server, is this possible?

I have found some threads on this forum explaining how but some are 10+ years old so I'm hoping there is a quick, easy and more up-to-date way of doing this?

Kind regards


James
 

keat63

Well-Known Member
Nov 20, 2014
1,963
267
113
cPanel Access Level
Root Administrator
Assume these external email addresses.

Eg, you want to stop somebody.com sending to all domains on your server ?

You can create an exim blacklist.
Take a look at post 3.
Block receiving emails from specific domain to any mailing list?

or

If you know the IP of the offending server, Block the IP in CSF Firewall.

or

Purchase and install CSF MailScanner and block them from there.
 
  • Like
Reactions: cPanelMichael

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463
Hello James,

The information in the previous post should help. Let us know if you have any questions.

Thanks!
 

jlucho

Well-Known Member
Aug 5, 2006
114
1
168
hi guys

I have the same search


for example , a sender: [email protected], he sends me messages and also to my hosting clients.

The current version of cPanel contemplates blocking specific senders, so that it cannot send me, and neither my hosting users?
 
Last edited:

keat63

Well-Known Member
Nov 20, 2014
1,963
267
113
cPanel Access Level
Root Administrator
I found that the exim blacklist wasn't fool proof.

CSF Mailscanner, whilst not free, it's not expensive either.
It's a brilliant tool for such as this.
You can block an email or a TLD at server level.

I'm not affiliated with CSF, but do highly recommend this tool.
 

murky.debate.3185

Registered
Nov 24, 2022
1
0
0
Sweden
cPanel Access Level
Website Owner
I found that the exim blacklist wasn't fool proof.

CSF Mailscanner, whilst not free, it's not expensive either.
It's a brilliant tool for such as this.
You can block an email or a TLD at server level.

I'm not affiliated with CSF, but do highly recommend this tool.
(Newbie)
Hi, where do i install the CSF mailscanner?
I have my own one.com domain.
 

ITHKBO

Active Member
Jun 23, 2020
36
35
18
Netherlands
cPanel Access Level
Root Administrator
(Newbie)
Hi, where do i install the CSF mailscanner?
I have my own one.com domain.
If you purchased the Front-end license (MSFE) you can follow the instructions below to get the basic setup done.
However as mentioned you need commandline, terminal access.

You would start with following the instructions here for the basic mailscanner: https://configserver.com/free-cpanel-mailscanner-installer/

Than move on to the next part outlined here: https://support.configserver.com/knowledgebase/article/installreinstall-mailscanner-front-end

Take note the first part in the instructions deals only with the prerequisites Razor and DCC after which at step 3 you get another script for the frond-end and automated installation.https://configserver.com/msfe-script-installer
After that step is done go back to the previous link and follow 4 to 5.

Again this setup *only* works if you have the paid license for your server IP and your purchase got approved.


If you meant you only got the free mailscanner (which is not from Way to the Web Configserver) than you can still use there free script *but only the basic installation*.
https://configserver.com/free-cpanel-mailscanner-installer/


If you rather not rely on a third party for the installation instructions at all the official developer instructions are availiable at https://www.mailscanner.info/install/
However from experience the script from Way to the Web Configserver works as intended and I do not see any benefit of not using it unless you have a very custom environment or specific setup restrictions.