-
-
Notifications
You must be signed in to change notification settings - Fork 413
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
Url decoding is only applied on the query parameters #992
Comments
Crow currently does not decode the URL path. |
Ok, I'm fine with this, however, is this typical for webservers? It seems like surprising behaviour. Can we document this? My route was coded something like:
IF this is the correct approach, then it would be nice to have a function that accepts a string and in-place decodes it. What do you think? |
Yo are welcome to add the function and the documentation. |
I've pushed a PR with test case. Was trying codespaces, is there a way to run the unit tests in there? |
https://github.com/CrowCpp/Crow/pull/993/checks |
I've forced-pushed. Do you have to re-approve each time? |
It seems. :) |
If I GET a url such as:
https://myserver.com/imgs/image with space.png?param=one two
the URL seen by the server is:
https://myserver.com/imgs/image%20with%20space.png?param=one%20two
The query parameters are decoded correctly, into:
param --> one two
However, the URL is still
imgs/image%20with%20space.png
Shouldn't crowcpp automatically decode the URL path before it is passed to a route handler?
ie I would expect my handler to see
imgs/image with space.png
Or are we expected to manually decode this?
The text was updated successfully, but these errors were encountered: