Welcome! Log In Create A New Profile

Advanced

Whitelisting IP addresses for ratelimiting

James Fidell
July 25, 2012 08:54AM
I have my configuration set up based on the information at
http://gadelkareem.com/2012/03/25/limit-requests-per-ip-on-nginx-using-httplimitzonemodule-and-httplimitreqmodule-except-whitelist/
as follows:

http {
....
geo $unlimited {
default 1;
192.168.45.56/32 0;
}
....
limit_req_zone $binary_remote_addr zone=unlimited:10m rate=10r/m;
....
server {
...
location / {
limit_req zone=unlimited burst=5;
}
}
}

I believe this should mean that requests from IP address 192.168.45.56
are not subject to the rate limiting, but it isn't working (they do get
blocked by the rate limiting) and I can't see why.

Is my configuration obviously wrong somewhere?

And if not, is there any way I can easily debug why the rate-limiting is
being applied?

Thanks,
James

_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

Whitelisting IP addresses for ratelimiting

James Fidell July 25, 2012 08:54AM

Re: Whitelisting IP addresses for ratelimiting

James Fidell July 25, 2012 08:58AM

Re: Whitelisting IP addresses for ratelimiting

Maxim Dounin July 25, 2012 09:48AM

Re: Whitelisting IP addresses for ratelimiting

James Fidell July 25, 2012 10:02AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 238
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready