Keeping GWT History Hashes thru Spring Security Login
-
12-11-2019 - |
Question
I'm retrofitting my application with GWT History support, and I've stumbled on a case where I'm not quite sure what to do. The answer to this question doesn't necessarily have to be GWT-related.
GWT's History support functions by passing around hash tags (i.e. index.html#token
). Security restrictions require users be logged in prior to actually being able to access index.html
, so they get sent over to a login page, retaining the token (login.html#token
). So far, so good. Now the user becomes authenticated and Spring sends them over to index.html
(the default target) and eliminates the #token
part of the URL.
How can I force Spring Security to maintain the token and send my newly authenticated user to the page they requested (index.html#token
)? Since I've already got Spring Security authentication working, I'd prefer to not restructure the way my app handles logins.
No correct solution