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

Fix URI rewrite in VirtualServers and VirtualServerRoutes #2267

Merged
merged 4 commits into from
Dec 15, 2021

Conversation

pleshakov
Copy link
Contributor

Proposed changes

Previously, if a rewrite was configured in a VS/VSR route, and the route had a split action, match action or a regex path, NGINX would mess up the arguments in the resulting rewrite. For example, the result would be /test%3Fhello=world?hello=world instead of the correct /test?hello=world

Fixes #1993

Tests:

  • Combine the VS and VSR tests into a single one.
  • Extend the tests to cover the bug fix.

@pleshakov pleshakov added the bug An issue reporting a potential bug label Dec 11, 2021
@nginx-bot nginx-bot force-pushed the fix-uri-rewrite branch 2 times, most recently from d7e1137 to d6c8c80 Compare December 14, 2021 18:06
Previously, if a rewrite was configured in a VS/VSR route, and the route
had a split action, match action or a regex path, NGINX would mess up
the arguments in the resulting rewrite. For example, the result would be
/test%3Fhello=world?hello=world instead of the correct /test?hello=world

Fixes #1993
- Combine the VS and VSR tests into a single one.
- Extend the tests to cover the bug fix.
@pleshakov pleshakov merged commit 4666d46 into master Dec 15, 2021
@pleshakov pleshakov deleted the fix-uri-rewrite branch December 15, 2021 23:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An issue reporting a potential bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

VirtualServer with conditional routes creates wrong rewrite rules
3 participants