Filter that enables a redirection in Browser to be able to redirect to pages which contain an anchor in the URL.
The sequence for login is:
- we try to access a page from a URL that may contain a hash to select a specific view (e.g. http://localhost:8080/one/#/TSK/eec1ca80-78a7/browse)
- Spring detects that we aren't logged in and creates a redirect to the login page (e.g. /login.jsp)
- this filter replaces the default redirection with a script that stores the hash before redirecting as Spring requested
- the hash is stored and we redirect to the login page
- after login, Spring again creates a redirect to the root page of the application
*
- this filter replaces that redirection with a script that restores the location from the original URL using the hash that we stored earlier
- the cookie storing the hash is cleared
The sequence for manual logout is:
- we select logout in the GUI, which performs the Spring logout calling j_spring_security_logout
- after the successful logout we are redirected back to the application (without a hash)
- this filter replaces that redirection with a script that restores the location from the original URL (no hash is stored, so this is the base page)
- the subsequent login proceeds as described above, but using the root application page with no hash