Skip to content
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

Policy: Routing fix URL encoding. #1208

Merged
merged 1 commit into from
Jun 30, 2020
Merged

Conversation

eloycoto
Copy link
Contributor

This commit fixes an issue when a special character uses some encoding.
The value to the upstream API if the routing policy was used, is also
encoded, so something like "/foo/test space" should land in APICast as:

/foo/test%20space/

And the path to the Upstream API should contain test%20space, but
because ngx.req.set_uri mark the URL to be encoded again, the URL that
will be received in the Upstream API will be /test%2520space/

This commit keeps the URL encoding correctly across all the flow.

Fix THREESCALE-5454

Signed-off-by: Eloy Coto [email protected]

@eloycoto eloycoto requested a review from a team as a code owner June 29, 2020 15:35
This commit fixes an issue when a special character uses some encoding.
The value to the upstream API if the routing policy was used, is also
encoded, so something like "/foo/test space" should land in APICast as:

`/foo/test%20space/`

And the path to the Upstream API should contain `test%20space`, but
because `ngx.req.set_uri` mark the URL to be encoded again, the URL that
will be received in the Upstream API will be `/test%2520space/`

This commit keeps the URL encoding correctly across all the flow.

Fix THREESCALE-5454

Signed-off-by: Eloy Coto <[email protected]>
@eloycoto eloycoto merged commit 674bdea into 3scale:master Jun 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants