Have used .htaccess files at site level in the past but with 30 odd sites on the server too overhead intensive. Now have 1000 ip ranges loaded in ConfigServer Security & Firewall IP Deny file and that works well. 1000 is the limit - is there any other way to block more ip ranges at the front end? ta Sheree
I would go to http://www.maxmind.com/app/mod_geoip and install the mod_geoip as it says on the website. You can then configure what countries to ban / redirect via server wide via the httpd.conf file. I implemented this today but via .htaccess to test it and so far it has blocked 99% of my chinese and Iranian traffic, and if all is good in a few days I will turn it on server wide. After much research, this is the most efficient way although installation is tricky if you don't know what you're doing. I don't think there is a decent solution via whm however I could be wrong
I haven't placed it in httpd.conf yet. Although after installation I placed the following code in my htaccess file. According to the maxmind site, it should do the same job but sitewide by placing it in httpd.conf # This blocks traffic from China, Russia and Iran GeoIPEnable On GeoIPDBFile /usr/local/etc/GeoIP.dat #replace above line with path to geoip.dat. I couldn't get this right so I just commented the above line and it still seemed to work fine. SetEnvIf GEOIP_COUNTRY_CODE CN BlockCountry SetEnvIf GEOIP_COUNTRY_CODE RU BlockCountry SetEnvIf GEOIP_COUNTRY_CODE IR BlockCountry # ... place more countries here Deny from env=BlockCountry # See http://httpd.apache.org/docs/1.3/mod/mod_access.html for more details Code (markup):