views:

129

answers:

3

Hi! I need that my apache require authentication only to external access but free in my local network. I have mod_user in my apache. ( sorry for my english :S )

Thx!!

A: 

Not much into apache authentication, i just use tomcat from time to time to test some jsp.

Have you tried reading this? http://httpd.apache.org/docs/1.3/howto/auth.html#basicconfig

fmsf
+1  A: 

The easiest way to deal with this is to use two virtual host. Use one for the external users and one of the internal users... i.e. "www.myhost.com" for external and "www-int.myhome.com" for internal users. Restrict www-int to internal IP's only with no auth requirements.

Alternatively, you can use something like this in your Auth directives:

Require valid-user
Allow from 192.168.1
Satisfy Any
James Schek
A: 

Hi everyone!

I'm budamolina, the one that posted the question.

Thanks a lot, "Satisfy any" works great!

fmsf: thanks for the apache.org URL, it was really useful.

Regards