Replies: 1 comment 1 reply
-
|
After some recent changes (#2468), you can use network specifiers as well, after looking at the code: https://github.com/encode/uvicorn/blob/master/uvicorn/middleware/proxy_headers.py#L67-L75 So something like |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
In the use case of kubernetes, where the reverse proxy pods can have any IP address looking like
192.168.*.*. Therefore it would make sense to allow adding IP addresses with wildcards in theforwarded_allow_ipslist, instead of specifying*to trust everything, or passing in a list of 254^2 (~65000) addresses.All that would be required is a little tweaking in the
ProxyHeadersMiddleware.get_trusted_client_hostmethodBeta Was this translation helpful? Give feedback.
All reactions