PDA

View Full Version : Bad bot blocking?


tortus32
02-17-2005, 11:10 AM
Does anyone know how to block bad bots?

Thanks,

Bill

swedguy
02-17-2005, 11:20 AM
By IP or coming from a certain domain?

tortus32
02-17-2005, 11:26 AM
Agent name.

I found this agent name as one of the latest visitors: EirGrabber
So I did a google search for "EirGrabber" and it turns out it's a bad bot.
Is that right?

Now when I go and check my latest visitor stats, I can't find it anymore.

Bill

swedguy
02-17-2005, 12:09 PM
Put this in your .htaccess. Notice that there's no OR in the last RewriteCond
RewriteEngine On
RewriteCond %{HTTP_USER_AGENT} ^.*eirgrabber [NC,OR]
RewriteCond %{HTTP_USER_AGENT} ^.*another_bad_bot [NC,OR]
RewriteCond %{HTTP_USER_AGENT} ^.*third_bad_bot [NC]
RewriteRule .* - [F,L]

But I wouldn't really sweat over it :)

tortus32
02-17-2005, 12:42 PM
Thanks!

Bill