Current Behavior
When the redirect plugin is used, requests with the 'x-forwarded-proto: http' header to access the https port will still be redirected
Expected Behavior
I believe the redirect plugin should provide a global parameter, such as "trust_x_forwarded_proto," that should be enabled by default. This parameter should remain enabled when APISix is behind another Layer 7 load balancer. Conversely, it should be disabled when APISix is the first Layer 7 load balancer.
For example, if one of my services receives a request from another gateway proxy with an "X-Forwarded-Proto: http" header, and I request the HTTPS port of the APISix route with redirection enabled, it will also return a redirect. I find this unreasonable.
Error Logs
No response
Steps to Reproduce
Simply requesting a route with the redirect plugin enabled with a different X-Forwarded-Proto header can be sufficient.
Environment
no need
Current Behavior
When the redirect plugin is used, requests with the 'x-forwarded-proto: http' header to access the https port will still be redirected
Expected Behavior
I believe the redirect plugin should provide a global parameter, such as "trust_x_forwarded_proto," that should be enabled by default. This parameter should remain enabled when APISix is behind another Layer 7 load balancer. Conversely, it should be disabled when APISix is the first Layer 7 load balancer.
For example, if one of my services receives a request from another gateway proxy with an "X-Forwarded-Proto: http" header, and I request the HTTPS port of the APISix route with redirection enabled, it will also return a redirect. I find this unreasonable.
Error Logs
No response
Steps to Reproduce
Simply requesting a route with the redirect plugin enabled with a different X-Forwarded-Proto header can be sufficient.
Environment
no need