-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
host_redirect cleans up the request port when port_redirect is not specified #17318
Comments
it lost the port |
you should set redirect-test.mydomain.com: 10080, it will work well |
This issue has been automatically marked as stale because it has not had activity in the last 30 days. It will be closed in the next 7 days unless it is tagged "help wanted" or "no stalebot" or other activity occurs. Thank you for your contributions. |
This issue has been automatically closed because it has not had activity in the last 37 days. If this issue is still valid, please ping a maintainer and ask them to label it as "help wanted" or "no stalebot". Thank you for your contributions. |
Can we re-open this ticket? There is a workaround as I mentioned in the description, but I still believe it is unexpected to clean up the port. |
@jparklab Would you show your workaround? I met this same problem, envoy modified the location header of a 302 response, the location header was modified from '/user/login' to 'http://$svc_name/user/login', and it lost port number in $svc_name but my default svc port is not 80, so it failed. |
@choldrim You can work around by specifying the redirect address with port as @chrisxrepo mentioned. #17318 (comment) |
Skips redirect tests that check for original request port in returned Location header, failing likely due to: envoyproxy/envoy#17318 Signed-off-by: Sunjay Bhatia <sunjayb@vmware.com>
Skips redirect tests that check for original request port in returned Location header, failing likely due to: envoyproxy/envoy#17318 Signed-off-by: Sunjay Bhatia <sunjayb@vmware.com>
reframing the ask - as a user I would only like to set the
and would like to leave the This can easily be solved by statically setting the We would like such a functionality in Envoy Gateway due to the way the redirect port has been defined in the Gateway API
|
hey @cpakulski can you ptal ? |
…tour#5063) Skips redirect tests that check for original request port in returned Location header, failing likely due to: envoyproxy/envoy#17318 Signed-off-by: Sunjay Bhatia <sunjayb@vmware.com> Signed-off-by: yy <yang.yang@daocloud.io>
…tour#5063) Skips redirect tests that check for original request port in returned Location header, failing likely due to: envoyproxy/envoy#17318 Signed-off-by: Sunjay Bhatia <sunjayb@vmware.com> Signed-off-by: yy <yang.yang@daocloud.io>
…tour#5063) Skips redirect tests that check for original request port in returned Location header, failing likely due to: envoyproxy/envoy#17318 Signed-off-by: Sunjay Bhatia <sunjayb@vmware.com>
Description:
When host_redirect is specified but port_redirect is not, port is not preserved in the response. Envoy cleans up the port in the response(https://github.com/envoyproxy/envoy/blob/main/source/common/router/config_impl.cc#L791).
Envoy should preserve the port in the request if port_redirect is not specified or it should be clarified in the doc(https://www.envoyproxy.io/docs/envoy/latest/api-v3/config/route/v3/route_components.proto#envoy-v3-api-msg-config-route-v3-redirectaction) that the port will be cleaned up if port_redirect is not specified.
Repro steps:
Config:
The text was updated successfully, but these errors were encountered: