0

block user agent in apache web server

Need to block user agent in apache web server say

"libwww-perl"

which is not needed??

ajinfernando
asked Sep 28, 2018
1 Answer
0

Assuming .htaccess is already enabled on your server (it is on most servers running Apache), add the following near the very top to block this user-agent from accessing your site.

cat .htaccess
<IfModule mod_rewrite.c>
  RewriteEngine On
  RewriteCond %{HTTP_USER_AGENT} ^libwww-perl [NC]
  RewriteRule .* - [F,L]
</IfModule>
View More
linuxhelp
answered Jan 29, 2019
Your Answer
||||
 
100:0

Related News in block user agent in apache web server

Related News in block user agent in apache web server