0

global configuration for blocking "bad bots"

Where can I add global configuration for blocking "bad bots" in cPanel Server?

binoweasley
asked Sep 24, 2018
1 Answer
0

Do the configuration in the following location

/usr/local/apache/conf/includes/previrtualhostglobal.conf

Say for example if you want to remove "libwww-perl" add the following in "/usr/local/apache/conf/includes/pre_virtualhost_global.conf"

<LocationMatch ".*">
  SetEnvIfNoCase User-Agent "^libwww-perl" bad_bot
  Deny from env=bad_bot
</LocationMatch>

<If "%{HTTP_USER_AGENT} == 'libwww-perl'">
  Deny from all
</If>

<Directory />
  SetEnvIfNoCase User-Agent "^libwww-perl" bad_bot
  Deny from env=bad_bot
</Directory>
View More
gokulravichandran2
answered Sep 28, 2018
Your Answer
||||
x
 
100:0