Block Libwww-perl bot


Libwww-perl is a perl botnet script which automatically checks for vulnerabilities, sometimes these types of scripts are identified as user agents
and these may cause security issues and consume bandwidth
but this can be eliminated by blocking the specific user agent with htaccess

What is .htaccess?

.htaccess is a configuration file for use on web servers running the Apache Web Server software.

When a .htaccess file is placed in a directory which is in turn ‘loaded via the Apache Web Server’
then the .htaccess file is detected and executed by the Apache Web Server software.
The htaccess file will be found in home directory of your webserver

/home/username/public_html (this is the default home directory in most of the apache servers
/home/username/html (mostly in godaddy servers)

How to Block Libwww-perl bot

If there is no .htaccess file found in your home directory then you have to create one
you can use filezilla or cyberduck to FTP into your webserver
create a file named .htaccess (Note: there is a dot in-front of htaccess)
just simply add the following code to your htaccess file, voila its done

RewriteEngine On
RewriteCond %{HTTP_USER_AGENT} libwww-perl.* [NC]
RewriteRule .* – [F,L]

Comments are closed.