I run a forum and the number of spam signups was getting beyond the joke. I used to do as you have been doing and block the IP's but they always popped up again. The majority are from bots and most now can crack a Captcha. What has proved to be most effective is having a simple questions and answer, I just have four that randomly rotate on each sign up. Haven't had a single spam sign up since I done it. http://www.xaprb.com/blog/2006/01/28/captchas-done-better/ gives an idea for PHP coding.
----- Original Message ----- From: "Ian Douglas" aluger@k1ngph1cher.com To: "ALUG List" main@lists.alug.org.uk Sent: Friday, November 18, 2011 9:25 AM Subject: [ALUG] How can I deny certain countries access to my website
For about a month one of my websites (or rather the "Contact Us" form on that website) has been under regular, daily, attack from hackers. The attacks are consistently coming from IP Addresses in Rumania and Russia. Each time an attack occurs I use my webhost's cPanel to manually add the IP to my cPanel "IP Deny Manager" list. This is however becoming rather tedious and time consuming and seems the wrong way round to do things as I am denying IP Addresses AFTER they have tried to hack in rather than blocking them BEFORE they attempt it.
Is there a way I can simply deny access to my website (or, better, just it's home-made PHP based "Contact Us" form) to all Eastern European visitors?
Alternatively, since my website is primarily focused on UK customers, would there be an easier way to deny all visitors access unless they came from UK, USA Canada, Eire or Australia?
I realise that this is not specifically a Linux question but any suggestions would be welcome.
Ian.
main@lists.alug.org.uk http://www.alug.org.uk/ http://lists.alug.org.uk/mailman/listinfo/main Unsubscribe? See message headers or the web site above!