From b1b053d3dcc32a14418ea5ca11ee1045e5f3974d Mon Sep 17 00:00:00 2001 From: ch-lepp Date: Mon, 9 Dec 2024 10:06:28 +0100 Subject: [PATCH] Other clients but Account-Management can link account Signed-off-by: Christian Leppelt Signed-off-by: ch-lepp --- .../org/keycloak/services/resources/IdentityBrokerService.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/services/src/main/java/org/keycloak/services/resources/IdentityBrokerService.java b/services/src/main/java/org/keycloak/services/resources/IdentityBrokerService.java index 8eb68f0d8488..59cb9420f2db 100755 --- a/services/src/main/java/org/keycloak/services/resources/IdentityBrokerService.java +++ b/services/src/main/java/org/keycloak/services/resources/IdentityBrokerService.java @@ -1176,7 +1176,7 @@ private AuthenticationSessionModel parseSessionCode(String code, String clientId private Response checkAccountManagementFailedLinking(AuthenticationSessionModel authSession, String error, Object... parameters) { UserSessionModel userSession = new AuthenticationSessionManager(session).getUserSession(authSession); - if (userSession != null && authSession.getClient() != null && authSession.getClient().getClientId().equals(Constants.ACCOUNT_MANAGEMENT_CLIENT_ID)) { + if (userSession != null && authSession.getClient() != null) { this.event.event(EventType.FEDERATED_IDENTITY_LINK); UserModel user = userSession.getUser();