1 |
>> I use apache2 authentication for web users and I would like to require |
2 |
>> logins from certain users to be from a certain IP address. I |
3 |
>> experimented with Allow and Require but couldn't find a way to restrict |
4 |
>> only certain users. Can this be done via apache2 authentication or |
5 |
>> should I use another method? |
6 |
>> |
7 |
>> - Grant |
8 |
> |
9 |
> |
10 |
> very simple via .htaccess |
11 |
> |
12 |
> <Limit GET POST> |
13 |
> order deny,allow |
14 |
> deny from all |
15 |
> allow from IP_address |
16 |
> </Limit> |
17 |
> |
18 |
> AuthName "restricted stuff" |
19 |
> AuthType Basic |
20 |
> AuthUserFile /etc/apache2/users |
21 |
> require user webmaster |
22 |
|
23 |
I think that will require any usernames specified to come from IP_address. |
24 |
I'm trying to allow certain usernames to come from any IP, and restrict |
25 |
other usernames to a certain IP. Can that be done via .htaccess? |
26 |
|
27 |
- Grant |