question access control
Maxim Dounin
mdounin at mdounin.ru
Thu Apr 7 05:08:20 MSD 2011
Hello!
On Thu, Apr 07, 2011 at 01:55:42AM +0200, Yanxin Z. wrote:
> Hello,
> I am trying to use access control to limit access from limited IP range.
>
> I test 127.0.0.1 first, with config
>
> server {
> listen 80;
> server_name localhost;
>
> location / {
>
> deny all;
>
> }
> }
>
> However, when I test in browser with 127.0.0.1, I can still see
> index.html page.
>
> Did I do something wrong?
Sure.
It's up to you to find out what exactly, possible causes include:
1. You are testing your browser cache, not nginx.
2. You've failed to configure virtual hosts properly and testing
wrong virtual host.
3. You've forgot to reload configuration and/or it wasn't reloaded
due to errors in config.
Maxim Dounin
More information about the nginx
mailing list