ModSecurity to disable for Wordpress

cPRex

Jurassic Moderator
Staff member
Oct 19, 2014
16,570
2,612
363
cPanel Access Level
Root Administrator
Hey there! I'm not sure if there is a one-size-fits-all solution to this problem. Some people have run into issues with the auto-save feature as mentioned here:


but it could be any number of ModSecurity rules on the system causing a problem.

The safest solution would be to examine the ModSecurity logs and whitelist the rules that are being tripped on your specific machine:


You can also whitelist a certain IP address, such as the home IP of the site admin:

 

ITHKBO

Active Member
Jun 23, 2020
41
39
18
Netherlands
cPanel Access Level
Root Administrator
I can provide you the list we use for our wordpress clients but I agree with cPRex that it is better to audit the logs.
Below is based on 3 months observations since 2023 on our new Cloudlinux server with 800 plugins spread between the accounts.
We have not had any new incidents for a few months now.

942100, 942140, 942190, 941100, 941110, 941120, 941130, 941140, 941160, 941170, 941180, 941210, 921110, 921130, 980130, 930100, 930110, 920120
 
Last edited by a moderator:
  • Like
Reactions: azednetma and cPRex

retechpro

Well-Known Member
Dec 23, 2022
141
16
18
Pakistan
cPanel Access Level
Root Administrator
I’ve same issue. I need to disable mod_security on whole server because client facing issue.

Some client facing post save issue.
Some client facing 404 error.
Some facing ajax error in plugins.

Which rules are creating issue. What should we have to do.

I’m using imunify360 & Cloudlinux. Is it safe to disable mod security on whole server?
 

ITHKBO

Active Member
Jun 23, 2020
41
39
18
Netherlands
cPanel Access Level
Root Administrator
  • Like
Reactions: cPRex

azednetma

Well-Known Member
Oct 27, 2015
68
4
58
Marrakech
cPanel Access Level
Root Administrator
Thank you!
This is my whitelist:

300013
300015
300016
300017
942100
942140
942190
941100
941110
941120
941130
941140
941160
941170
941180
941210
921110
921130
980130
930100
930110
920120
949110
980130

Anyhting to add or to remove?