Open jirinapravnik opened 1 year ago
There is a workaround you could to on your side.
When user clicks /saml/login
you can save to session their current route.
You can then extend the DefaultAuthenticationSuccessHandler
if you don't have your own.
Then load the route from session and return a RedirectResponse
@jirinapravnik hi!
If your /account/me
page there is behind the firewall that use this bundle, you'll be redirected for it automatically after successful log in.
\Symfony\Component\Security\Http\Firewall\ExceptionListener
persist the request URI at the moment when redirects you for login and then we pass this URI to the SAML server, which returns it in RelayState
(if not, this URI will still be used by SamlAuthenticationSuccessHandler).
Is it possible to set returnTo parametr via $_GET or something like that?
I have url /saml/login. I want to redirect always from page, where I click on login button. I would like to set something like /saml/login?returnTo=/account/me and after login (or logout) get to page /account/me etc.