httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sean T Allen <>
Subject Re: [users@httpd] Apache config directives based on requestor ip address?
Date Fri, 10 Dec 2004 17:30:12 GMT
mod_rewrite can be used to accomplish what you want in spirit if not in 
the design you
have below.

Andrew Boyce-Lewis wrote:

>I am looking for a way to apply alternative configuration directives to
>apache based on the source ip address. Basically, I was to do something
>like this:
><VirtualHost *>
>        ServerName
>	<RequesterMatch>
>		DocumentRoot /var/web/root/a
>	<RequesterMatch>
>	<RequesterMatch !>
>		DocumentRoot /var/web/root/b
>	<RequesterMatch>
>Obviously the RequesterMatch directive does not exist. Has anyone solved
>this problem in the past? I can think of a number of somewhat ugly ways
>to solve this problem using iptables, but an elegant solution would be
>Any ideas and/or experience with such problems?
>	-Andrew

View raw message