Forum Moderators: phranque

Message Too Old, No Replies

mod_geoip Apache Error

         

Zandaline

11:46 pm on Feb 16, 2006 (gmt 0)

10+ Year Member



I installed mod_geoip and everything seems to have gone well. I placed this into my httpd.conf:

GeoIPDBFile /download/mod_geoip/GeoIP.dat

SetEnvIf GEOIP_COUNTRY_CODE CN BlockCountry
SetEnvIf GEOIP_COUNTRY_CODE RU BlockCountry
Deny from env=BlockCountry

Then Apache refuses to restart. I did some digging and I have a Syntax Error. That error is: "deny not allowed here"

So I go back and comment out: Deny from env=BlockCountry

And it restarts just fine so I found the offending line. Of course if I comment out that line I can't block the countries. Can anyone help me figure out what I'm doing wrong?

-Z

jdMorgan

12:27 am on Feb 17, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Zandaline,

Welcome to WebmasterWorld!

What httpd.conf container is the code in? - <VirtualHost>? <Directory>?

Look at the allowable Contexts for Allow/Deny in mod_access -- that'll probably answer your question.

Jim