I've successfully set up rate limiting on IP addresses like so,
limit_req_zone $binary_remote_addr zone=one:10m rate=1r/s;
But I was wondering if its possible to do the same on referrers? For example, if a site gets placed in an iframe on a third party site, which generates too much traffic to handle.
I can't find any nginx variables for the referrer anywhere.
I don't want to block traffic completely, just limit the traffic that comes from an iframe.
Is this possible? Or can the solution be achieved in a different way?
Thanks.