Author Topic: Custom modsec rules  (Read 1238 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
Custom modsec rules
« on: January 11, 2023, 08:04:00 PM »
Hi
I need to know how to put a custom rule in CWP account for blocking some countries using modsec

Where I need to add the rules instructions? In which file?

Greetings

Offline
****
Re: Custom modsec rules
« Reply #1 on: January 14, 2023, 11:59:47 PM »
Have you considered blocking at the CSF/LFD firewall level instead of mod_security?

Otherwise, the answer to your question is here. File for custom directives is:
Code: [Select]
nano /usr/local/apache/modsecurity-cwaf/custom_user.conf
« Last Edit: January 15, 2023, 12:33:34 AM by overseer »