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

WebSessionServerRequestCache doesn't save URL query parameters #6421

Closed
denisw opened this issue Jan 14, 2019 · 0 comments
Closed

WebSessionServerRequestCache doesn't save URL query parameters #6421

denisw opened this issue Jan 14, 2019 · 0 comments
Assignees
Labels
in: web An issue in web modules (web, webmvc) type: bug A general bug
Milestone

Comments

@denisw
Copy link
Contributor

denisw commented Jan 14, 2019

Summary

When protecting a Webflux route with oauth2login(), the redirect back to that route after login misses any query parameters passed in the original request to that route. That seems to be caused by WebSessionServerRequestCache only saving the path, not the parameters.

For the purposes of the following sections, let's say the client requests GET /protected?foo=bar, but is not logged in yet.

Actual Behavior

After the OAuth2 login flow succeeded, the client gets redirected to /protected (note the missing ?foo=bar).

Expected Behavior

The query parameters are retained. The redirect after login would go to /protected?foo=bar.

Details

It seems as if WebSessionServerRequestCache only saves the request path. It should save URL query parameters in addition.

@rwinch rwinch added status: ideal-for-contribution An issue that we actively are looking for someone to help us with status: waiting-for-triage An issue we've not yet triaged and removed status: ideal-for-contribution An issue that we actively are looking for someone to help us with labels Jan 14, 2019
@rwinch rwinch removed the status: waiting-for-triage An issue we've not yet triaged label Jan 15, 2019
@rwinch rwinch self-assigned this Jan 15, 2019
@rwinch rwinch added in: web An issue in web modules (web, webmvc) type: bug A general bug Reactive labels Jan 15, 2019
@rwinch rwinch added this to the 5.2.0.M1 milestone Jan 15, 2019
rwinch pushed a commit that referenced this issue Jan 15, 2019
Previously, URL query parameters were lost when saving a request
in WebSessionServerRequestCache. Now it is properly saved and
restored.

Fixes: gh-6421
rwinch added a commit that referenced this issue Jan 15, 2019
Previously, URL query parameters were lost when saving a request
in WebSessionServerRequestCache. Now it is properly saved and
restored.

Fixes: gh-6421
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: web An issue in web modules (web, webmvc) type: bug A general bug
Projects
None yet
Development

No branches or pull requests

2 participants