x_forwarded_for = headers.get("X-Forwarded-For") if x_forwarded_for is None: x_forwarded_for = ipaddress.IPv4Address._string_from_ip_int( randint(0, MAX_IPV4) )
The original author claims this is to prevent API gateway from leaking the true client IP.
The original author claims this is to prevent API gateway from leaking the true client IP.