Top

Install ModSecurity Rules to DirectAdmin with Custombuild

CustomBuild – options.conf

Make sure your options.conf have:

modsecurity_ruleset=none

Configuration file – malware_expert.conf

Generate custom folder first, where we put malware_expert.conf configuration file:

[root@directadmin]# cd /usr/local/directadmin/custombuild
[root@directadmin]# mkdir custom
[root@directadmin]# mkdir custom/modsecurity
[root@directadmin]# mkdir custom/modsecurity/conf

Add new file malware_expert.conf to custom/modsecurity/conf folder:

[root@directadmin]# nano -w /usr/local/directadmin/custombuild/custom/modsecurity/conf/malware_expert.conf

Add line to file and replace SerialKey with your subscription serial key!

SecRemoteRules SerialKey https://rules.malware.expert/download.php?rules=generic

NOTE! Make sure you update custombuild:

[root@directadmin]# ./build modsecurity_rules

and check that custombuild add malware_expert.conf file to /etc/modsecurity.d/ folder

Restart web-server