Redirect behavior
Peperud opened this issue · comments
Peperud commented
Thinking out loud...
- The default way for a reverse proxy to handle redirects should be to let them go back to the client. By default
HttpClient
does not do that. - While passing redirect responses back to the client, the proxy should be cleaver enough to detect which URLs point to the upstream server behind the proxy and change them to point to the proxy instead (otherwise the client will bypass the proxy when following the redirect).
- If a
HttpClientHandler
withAllowAutoRedirect = false
is passed in the options, the redirects seem to go through, however the301
responses reach the client unaltered and the proxy is bypassed on the next request.
ASP.NET Hello Bot commented
This issue was moved to aspnet/Home#2502