Welcome! Log In Create A New Profile

Advanced

Re: Exclude ip's from Nginx limit_req zone

December 24, 2014 02:36PM
Thanks for your reply Maxim Dounin

So something like this ? :

Main nginx conf:

http {

geo $limited {
default 1;
192.168.45.56/32 0;
199.27.128.0/21 0;
173.245.48.0/20 0;
103.21.244.0/22 0;
103.22.200.0/22 0;
103.31.4.0/22 0;
141.101.64.0/18 0;
108.162.192.0/18 0;
190.93.240.0/20 0;
188.114.96.0/20 0;
197.234.240.0/22 0;
198.41.128.0/17 0;
162.158.0.0/15 0;
104.16.0.0/12 0;
}

map $limited $limit {
1 $binary_remote_addr;
0 "";
}


And this on the domain config? :

server {

limit_req_zone $limit zone=foo:1m rate=10r/m;
limit_req zone=foo burst=5;
Subject Author Posted

Exclude ip's from Nginx limit_req zone

ASTRAPI December 20, 2014 06:18PM

Re: Exclude ip's from Nginx limit_req zone

mex December 21, 2014 05:25AM

Re: Exclude ip's from Nginx limit_req zone

Martin Frb December 21, 2014 05:52AM

Re: Exclude ip's from Nginx limit_req zone

ASTRAPI December 21, 2014 07:17AM

Re: Exclude ip's from Nginx limit_req zone

Francis Daly December 21, 2014 09:42AM

Re: Exclude ip's from Nginx limit_req zone

ASTRAPI December 21, 2014 10:11AM

Re: Exclude ip's from Nginx limit_req zone

B.R. December 21, 2014 11:26AM

Re: Exclude ip's from Nginx limit_req zone

ASTRAPI December 21, 2014 01:36PM

Re: Exclude ip's from Nginx limit_req zone

ASTRAPI December 24, 2014 09:01AM

Re: Exclude ip's from Nginx limit_req zone

Maxim Dounin December 24, 2014 09:34AM

Re: Exclude ip's from Nginx limit_req zone

ASTRAPI December 24, 2014 02:36PM

Re: Exclude ip's from Nginx limit_req zone

Maxim Dounin December 25, 2014 08:14AM

Re: Exclude ip's from Nginx limit_req zone

ASTRAPI December 25, 2014 01:32PM

Re: Exclude ip's from Nginx limit_req zone

ASTRAPI December 29, 2014 05:13PM

Re: Exclude ip's from Nginx limit_req zone

ASTRAPI January 03, 2015 07:35PM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 256
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