mod_geo enabled but not working on htaccess

خرید بک لینک

Yesterday, 09:16 AM #1

Hi,

i have reseller hosting and i have enabled a domain with mod_geoip module v 1.1.1 when phpinfo i see module is working and loaded.

i have also GeoIP.dat file

Code:


<IfModule mod_geoip.c>
GeoIPEnable On
GeoIPDBFile /home/useamefromdomain/domains/domainname.nl/public_html/GeoIP.dat
</IfModule>


 
SetEnvIf GEOIP_COUNTRY_CODE CN BlockCountry
SetEnvIf GEOIP_COUNTRY_CODE RU BlockCountry
SetEnvIf GEOIP_COUNTRY_CODE NL BlockCountry
Deny from env=BlockCountry
does nothing anyone knows the fix? i want block countrys by using .htaccess with geoip db

Yesterday, 09:34 AM #2

Quote Originally Posted by rodogino

i want block countrys by using .htaccess with geoip db

I'm not really able to help you with your issue, but is there a reason why you want to block countries with mod_geo?

If you want to block a country server wide it would be better to look at CSF to do this.

With kind regards,
Niels

Aphotrax.eu | https://aphotrax.eu


Yesterday, 09:49 AM #3

Quote Originally Posted by vlijmenlive
I'm not really able to help you with your issue, but is there a reason why you want to block countries with mod_geo?

If you want to block a country server wide it would be better to look at CSF to do this.

Hoi Vlijmen,

geo better way working with blocking.. i have one ban script in php with geoip.inc file this one works correct....
but need directly working from htaccess.. no need for csf for this easy job i think.


Yesterday, 12:05 PM #4

If you only want to block Apache requests this would indeed be a way. The reason I suggested CSF is because my assumption was that you wanted to block countries due to abuse/spam. In that case not only Apache is a target but all services so your solution wouldn't be solid.

But unfortunately no experience in the needed rules.

With kind regards,
Niels

Aphotrax.eu | https://aphotrax.eu


Yesterday, 12:47 PM #5

My thoughts, do you have htscanner enabled?
Ex-Ads, exchange text ads

DirectAdmin Forums...

ما را در سایت DirectAdmin Forums دنبال می‌کنید

برچسب: نویسنده: ایمان اصلاحی بازدید: 329 تاريخ: چهارشنبه 8 آذر 1396 ساعت: 14:10

صفحه بندی