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

Arguments with url encoded forward slashes no longer work #2176

Closed
aranel616 opened this issue Mar 19, 2017 · 3 comments
Closed

Arguments with url encoded forward slashes no longer work #2176

aranel616 opened this issue Mar 19, 2017 · 3 comments
Labels

Comments

@aranel616
Copy link

@aranel616 aranel616 commented Mar 19, 2017

After upgrading from 3.7.0 to 3.8.0, routes that contain a url encoded forward slash no longer work.

Example route: /auth/{code}
Example url: /auth/4%2FGtXcKpxJQk97MyRtHOy_6sPKrLz74-nDkKG6-iz-PIc

This route will no longer be triggered for that URL. I think the culprit is c2d7ae4, which started URL decoding the URI.

I'm working around this issue currently by double URL encoding the parameter (so the example url from above would be 4%252FGtXcKpxJQk97MyRtHOy_6sPKrLz74-nDkKG6-iz-PIc).

@akrabat
Copy link
Member

@akrabat akrabat commented Mar 19, 2017

That'd be a bc break then… sorry.

akrabat added a commit to akrabat/Slim that referenced this issue Mar 19, 2017
Revert slimphp#1946 as it breaks the case when a slash is URL-encoded within a
segment. See issue slimphp#2176

This reverts commit c2d7ae4, reversing
changes made to 7aabd47.
@akrabat akrabat mentioned this issue Mar 19, 2017
@akrabat
Copy link
Member

@akrabat akrabat commented Mar 19, 2017

Fixed in version 3.8.1.

Thank you for reporting and I'm sorry for the inconvenience.

@akrabat akrabat closed this Mar 19, 2017
@garnold
Copy link

@garnold garnold commented Jun 5, 2017

FWIW I bumped into what I thought was this issue, but the trouble was actually with Apache. The fix was to add AllowEncodedSlashes NoDecode inside my VirtualHost:

https://stackoverflow.com/questions/4390436/need-to-allow-encoded-slashes-on-apache

Hope this helps,
Geoff.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.