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
which is a secured view, causing another sign-in request and so on, resulting in a looping and finally "too many redirects" error.
How can one reproduce the bug?
Steps to reproduce the behavior:
Set up an OpenID login in backend and the dashboard
In the backend configuration set subject_key to some value that is not provided by id_token from your OIDC provider
Try to sign-in to via the dashboard
What is the expected behavior?
Ideally more user-friendly error in the console and not just OpenId authentication failed: AuthorizationError and redirect to an failed sign-in view that doesn't require signed session
What is your host/environment?
Version 1.3.2
Plugins - default installation of OpenSearch using Helm charts
Do you have any additional context?
Handling exception by redirecting to login happens in security-dashboards-plugin/server/auth/types/openid/routes.ts - the scope of try-catch there is quite broad so any exception that happens there will result in an infinite loop like that.
In my case id_token didn't contain email field, which backend security plugin required and hence
const user = await this.securityClient.authenticateWithHeader(
request,
this.openIdAuthConfig.authHeaderName as string,
`Bearer ${tokenResponse.idToken}`
);
was throwing AuthorizationException
The text was updated successfully, but these errors were encountered:
What is the bug?
Any exception during OIDC sign-in causes redirect to login:
which is a secured view, causing another sign-in request and so on, resulting in a looping and finally "too many redirects" error.
How can one reproduce the bug?
Steps to reproduce the behavior:
subject_key
to some value that is not provided byid_token
from your OIDC providerWhat is the expected behavior?
Ideally more user-friendly error in the console and not just
OpenId authentication failed: AuthorizationError
and redirect to an failed sign-in view that doesn't require signed sessionWhat is your host/environment?
Do you have any additional context?
Handling exception by redirecting to login happens in
security-dashboards-plugin/server/auth/types/openid/routes.ts
- the scope oftry-catch
there is quite broad so any exception that happens there will result in an infinite loop like that.In my case
id_token
didn't containemail
field, which backend security plugin required and hencewas throwing
AuthorizationException
The text was updated successfully, but these errors were encountered: