-
Notifications
You must be signed in to change notification settings - Fork 8
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unit test for Forwarded Headers Middleware #967
Conversation
Cherry pick to beta success |
Cherry pick to beta success |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One minor concern about this is that always enabling XForwardedFor allows client spoofing. (anybody can fake their ip address just by sending this header), when the App is not deployed behind a Proxy (LoadBalancer).
So, Apps that are exposed directly to internet (not recommended) could "suffer" this Issue.
I think that it's ok, any secure webapp should be deployed behind a Proxy/LoadBalancer.
…PNETCORE_FORWARDEDHEADERS_ENABLED environment variable is true.
You raise a valid concern about potential IP spoofing when enabling X-Forwarded-For headers without being deployed behind a proxy or load balancer. |
Cherry pick to beta success |
Add a test for X-Forward headers and RemoteAddress function.