简体   繁体   English

如何使用 .htaccess 阻止来自“BOT/0.1 (BOT for JCE)”的攻击?

[英]How to block attacks from “BOT/0.1 (BOT for JCE)” using .htaccess?

I have noticed an increase in attacks from this user agent:我注意到来自这个用户代理的攻击有所增加:

BOT/0.1 (BOT for JCE)

Request line is:请求行是:

POST /index.php?option=com_jce&task=plugin&plugin=imgmanager&file=imgmanager&version=1576&cid=20 HTTP/1.1

I have tried to block the bot with the following code in the .htaccess file:我试图在.htaccess文件中使用以下代码阻止机器人:

SetEnvIfNoCase User-Agent “BOT for JCE” bad_bot
<Limit GET POST>
Order Allow,Deny
Allow from all
Deny from env=bad_bot
</Limit>

But the above is not stopping the bots/attacks.但以上并不能阻止机器人/攻击。 How can I stop them?我怎样才能阻止他们?

Try:尝试:

RewriteEngine On
RewriteCond %{HTTP_USER_AGENT} BOT/0\.[0-9]
RewriteRule ^ - [L,F]

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM