apache / openwhisk-apigateway

Apache OpenWhisk API Gateway service for exposing actions as REST interfaces.
https://openwhisk.apache.org/
Apache License 2.0
64 stars 45 forks source link

x-forwarded-port makes little sense #310

Open akrabat opened 6 years ago

akrabat commented 6 years ago

Given that I have an API gateway set up like this: wsk api create /base /test GET test -n testapi --response-type http, then I can access it like this:

$ curl https://service.eu.apiconnect.ibmcloud.com/gws/apigateway/api/2fb...be1/base/test

Inspecting __ow_headers, I find this:

"x-forwarded-url": "https://service.eu.apiconnect.ibmcloud.com/gws/apigateway/api/2fb...be1/base/test",
"x-forwarded-port": "8080",

The URL is correct, but the port should be 443.

mhamann commented 5 years ago

@akrabat in your opinion, should we just remove the x-forwarded-port header?

akrabat commented 5 years ago

I think that x-forwarded-port should be correct.

rabbah commented 5 years ago

443 in this case.