I have try mod_geoip and combined with mod security as below :
--------------------------------------------------------------------------------------
>> http://dev.maxmind.com/geoip/legacy/mod_geoip2/
>> http://www.modsecurity.org/projects/modsecurity/apache/feature_geo_ip_lookups.html
--------------------------------------------------------------------------------------
After mod_geoip and db binary file from MaxMind installed, lsws v4.2.6 - v4.2.5 - v4.2.4 are always ignoring this basic rule :
But then I'm switching to apache and, voila! the rule above get just work as expected.
While using lsws, I have done setting Yes/No for "Enable IP GeoLocation" LiteSpeed option and also placing the righ path for "IP to GeoLocation DB".
I hope there will be an lsws bug fix patch or new version launch regarding to this "SecGeoLookupDb" and "@geoLookup" operator issue/bug.
--------------------------------------------------------------------------------------
>> http://dev.maxmind.com/geoip/legacy/mod_geoip2/
>> http://www.modsecurity.org/projects/modsecurity/apache/feature_geo_ip_lookups.html
--------------------------------------------------------------------------------------
After mod_geoip and db binary file from MaxMind installed, lsws v4.2.6 - v4.2.5 - v4.2.4 are always ignoring this basic rule :
Code:
SecGeoLookupDb /path/to/directory-of/GeoIP.dat
SecRule REMOTE_ADDR "@geoLookup" "chain,drop,msg:'Non-UK IP address'"
SecRule GEO:COUNTRY_CODE "!@streq UK" "t:none"
While using lsws, I have done setting Yes/No for "Enable IP GeoLocation" LiteSpeed option and also placing the righ path for "IP to GeoLocation DB".
I hope there will be an lsws bug fix patch or new version launch regarding to this "SecGeoLookupDb" and "@geoLookup" operator issue/bug.