You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using a custom authenticator throwing an AccountNotLinkedException (I'm not using "connect" feature), the user is redirected to the login_path with an http request parameter named error containing the error message.
Expected Behavior
With hwi/oauth-bundle previous version, the failure_path was used and a Session parameter containing the authentication error was available.
Right now the failure_path is not used if we are not using "connect" feature (I'm aware of this PR #1990 that fix part of the issue but not the session parameter issue).
Steps to Reproduce
I over simplify the Authenticator in purpose, the real one contains much more code.
Finding a way to keep the Symfony default failure handler while adding the specific things needed for the "connect" feature can be a way to avoid those issues. WDTY @stloyd ?
BTW reading how the "connect" feature is getting the authentication error, I think there is a way to simply remove this custom failure handler and simply change how the RegisterController is retrieving the authentication error.
I do it like this in my own custom one :
The text was updated successfully, but these errors were encountered:
Prometee
changed the title
failure_path is not used when "connect" feature is not usedfailure_path is not used when "connect" feature is disabled
Jul 10, 2024
Actual Behavior
Using a custom authenticator throwing an
AccountNotLinkedException
(I'm not using "connect" feature), the user is redirected to thelogin_path
with an http request parameter namederror
containing the error message.Expected Behavior
With
hwi/oauth-bundle
previous version, thefailure_path
was used and aSession
parameter containing the authentication error was available.Right now the
failure_path
is not used if we are not using "connect" feature (I'm aware of this PR #1990 that fix part of the issue but not the session parameter issue).Steps to Reproduce
I over simplify the Authenticator in purpose, the real one contains much more code.
Possible Solutions
Right now I override the failure handler service definition like this (⚠️ this can work only if you are not using "connect" feature) :
Finding a way to keep the Symfony default failure handler while adding the specific things needed for the "connect" feature can be a way to avoid those issues. WDTY @stloyd ?
BTW reading how the "connect" feature is getting the authentication error, I think there is a way to simply remove this custom failure handler and simply change how the
RegisterController
is retrieving the authentication error.I do it like this in my own custom one :
The text was updated successfully, but these errors were encountered: