Very simple bot blocking utility in php and iptables(ww.com)
ww.com
Very simple bot blocking utility in php and iptables
http://ww.com/stopbots.tar
4 comments
Neat!
Thank you, I'll definitely look in to it. The biggest problem with blocking bots is false positives, identifying and giving a pass to your real users. It's a surprisingly hard problem, bot writers are quite clever when it comes to masquerading as real users.
Thank you, I'll definitely look in to it. The biggest problem with blocking bots is false positives, identifying and giving a pass to your real users. It's a surprisingly hard problem, bot writers are quite clever when it comes to masquerading as real users.
in this thread http://news.ycombinator.com/item?id=686114 I promised to post this code, I've cleaned it up a little bit.
It's not the most elegant solution and I'm sure the code can be improved upon but it does the job.
It's not the most elegant solution and I'm sure the code can be improved upon but it does the job.
[deleted]
The advantage of this script is that it directly monitors the IPs using netstat so one could stop bots from hammering things other than your webserver, say socket connections.
It is customizable to use APF or iptables and worked quite well when one of my friend's site was hit.