3

We have many layers before Kong server.

How can we use the plugin rate-limiting to limit requests by every enduser's client IP?

I want the plugin rate-limiting to read the header X-Forwarded-For to get the users real IP. But I think it is using $remote_ip by rate-limiting.

Any suggestions?

Ralf
  • 16,086
  • 4
  • 44
  • 68
stoner
  • 39
  • 6
  • Looks like we are in the same race, we are also trying to implement the same but so far no luck. Did you get any clue so far? I am planning to use set_real_ip_from , and real_ip_header. – PratapSingh Jul 17 '18 at 08:06
  • 1
    yes, pass real $remote_ip to Kong, if you can set the intermediate proxy – stoner Jul 25 '18 at 07:29
  • Enabling "proxy_set_header X-Forwarded-For remote_addr" and "real_ip_header X-Forwarded-For;" worked, however, I could not find any way around this. – PratapSingh Jul 25 '18 at 07:48
  • are you setting this in Kong or somewhere else? I'm trying to use the real IP from X-Forwarded-For, since the call was forwarded to Kong. Using it for the IP Restriction plugin. – fei0x Jun 11 '19 at 18:32

0 Answers0