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
I am integrating Keycloak with an external OAuth 2.0 identity provider and have encountered an edge case related to email uniqueness conflicts during manual account linking.
Configuration
Sync Mode: FORCE (user attributes, including email, are updated on every login)
First Broker Login: Manual linking is supported, allowing users to link IdP accounts to existing Keycloak accounts even without matching attributes
Scenario
User has an existing local Keycloak account (userA) with email [email protected] (not linked to the IdP)
The same person logs in via the identity provider with email [email protected]
During first broker login flow, the user manually links the IdP account to a different Keycloak account with email [email protected]
The error is caught and rendered with a generic error page.
Question
What would be the best approach to provide a clearer, more actionable error message to users? Is there a better way to handle this situation gracefully?
Any guidance or best practices on handling this scenario would be greatly appreciated!
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
-
Hello,
I am integrating Keycloak with an external OAuth 2.0 identity provider and have encountered an edge case related to email uniqueness conflicts during manual account linking.
Configuration
FORCE
(user attributes, including email, are updated on every login)Scenario
userA
) with email[email protected]
(not linked to the IdP)[email protected]
[email protected]
[email protected]
to[email protected]
[email protected]
already exists (duplicate emails not allowed in the realm)Current Behavior
Messages.IDENTITY_PROVIDER_UNEXPECTED_ERROR
)Technical Details
The exception occurs in the following call chain:
The error is caught and rendered with a generic error page.
Question
What would be the best approach to provide a clearer, more actionable error message to users? Is there a better way to handle this situation gracefully?
Any guidance or best practices on handling this scenario would be greatly appreciated!
Beta Was this translation helpful? Give feedback.
All reactions