Required Help on satisfy any setup

Francis Daly francis at
Tue Feb 24 20:59:24 UTC 2015

On Tue, Feb 24, 2015 at 10:13:26AM -0500, mathi wrote:

Hi there,

> I am using 2 layer NGINX. Fist layer NGINX works as a load balancer and
> forwards all HTTP traffic another NGINX based on HTTP or HTTPS.
> When i setup below conditions its not working.
> location / {
>  satisfy any;
>  allow xx.xx.xx.xx/32;
>  allow yy.yy.yy.yy/32;
>   auth_basic "Restricted"

Missing semicolon on the previous line.

>  auth_basic_user_file /etc/nginx/password;
> }

This can work on the first nginx, because it knows the real client address.

If you want it to work on the second nginx, you probably need to use - but I have
not tested that myself.

Francis Daly        francis at

More information about the nginx mailing list