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

Don't decode and re-encode URLs unnecessarily. #96

Merged
merged 1 commit into from
Dec 17, 2022

Conversation

dimaryaz
Copy link
Contributor

@dimaryaz dimaryaz commented Aug 5, 2022

This causes two problems:

  • '+' gets incorrectly decoded to ' '
  • '%2B' gets decoded to '+', but not encoded back to '%2B', resulting in a slightly different URL

Fixes #95

This causes two problems:
- '+' gets incorrectly decoded to ' '
- '%2B' gets decoded to '+', but not encoded back to '%2B', resulting in a slightly different URL

Fixes evanmiller#95
@evanmiller
Copy link
Owner

Thanks!

@evanmiller evanmiller merged commit d2d77c4 into evanmiller:master Dec 17, 2022
dimaryaz added a commit to quiltdata/mod_zip that referenced this pull request Feb 11, 2023
This reverts evanmiller#96, with the exception of not decoding '+' to ' '.

The change in evanmiller#96 fixed evanmiller#95 but introduced evanmiller#102. It appears to be impossible to fix both bugs without modifying Nginx itself.
However, the second part of the original bug was really a problem with S3 rather than mod_zip, so mod_zip functionality should take priority.

Therefore, bring back original behavior - except for decoding '+' to ' ', which was still a bug in mod_zip.

This fixes evanmiller#102.
evanmiller pushed a commit that referenced this pull request Feb 13, 2023
This reverts #96, with the exception of not decoding '+' to ' '.

The change in #96 fixed #95 but introduced #102. It appears to be impossible to fix both bugs without modifying Nginx itself.
However, the second part of the original bug was really a problem with S3 rather than mod_zip, so mod_zip functionality should take priority.

Therefore, bring back original behavior - except for decoding '+' to ' ', which was still a bug in mod_zip.

This fixes #102.
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.

Unnecessary (and slightly incorrect) URL decoding / re-encoding
3 participants