Hello,
i want to disable some crawler access to some of websites on my server so i tried to write a custom httpd.conf rule below;
and after saving it to custom httpd.conf apache gives this error:
line 22 is "Order allow,deny" so, there are some tokens to use in this field but i'm not familiar with this custom httpd.conf settings, any help will be appreciated. thank you.
i want to disable some crawler access to some of websites on my server so i tried to write a custom httpd.conf rule below;
Code:
SetEnvIfNoCase User-Agent .*rogerbot.* bad_bot
SetEnvIfNoCase User-Agent .*exabot.* bad_bot
SetEnvIfNoCase User-Agent .*mj12bot.* bad_bot
SetEnvIfNoCase User-Agent .*dotbot.* bad_bot
SetEnvIfNoCase User-Agent .*gigabot.* bad_bot
SetEnvIfNoCase User-Agent .*ahrefsbot.* bad_bot
SetEnvIfNoCase User-Agent .*sitebot.* bad_bot
SetEnvIfNoCase User-Agent "^Baiduspider" bad_bot
SetEnvIfNoCase User-Agent "^Sogou" bad_bot
Order allow,deny
Allow from all
Deny from env=bad_bots
and after saving it to custom httpd.conf apache gives this error:
Code:
Syntax error on line 22 of /usr/local/directadmin/data/users/xxxxxx/httpd.conf:
order not allowed here
line 22 is "Order allow,deny" so, there are some tokens to use in this field but i'm not familiar with this custom httpd.conf settings, any help will be appreciated. thank you.