services/src/main/java/org/keycloak/services/managers/AuthenticationManager.java
// Logout all clientSessions of this user and client
Logout all clientSessions of this user and client
Logout all clientSessions of this user and client
public static void backchannelUserFromClient(KeycloakSession session, RealmModel realm, UserModel user, ClientModel client, UriInfo uriInfo, HttpHeaders headers) {
        String clientId = client.getId();
        List<UserSessionModel> userSessions = session.sessions().getUserSessions(realm, user);
        for (UserSessionModel userSession : userSessions) {
            List<ClientSessionModel> clientSessions = userSession.getClientSessions();
            for (ClientSessionModel clientSession : clientSessions) {
                if (clientSession.getClient().getId().equals(clientId)) {
                    AuthenticationManager.backchannelLogoutClientSession(session, realm, clientSession, userSession, uriInfo, headers);
                    TokenManager.dettachClientSession(session.sessions(), realm, clientSession);
                }
            }
        }
    }
public static void backchannelUserFromClient ( KeycloakSession session , RealmModel realm , UserModel user , ClientModel client , UriInfo uriInfo , HttpHeaders headers ) { String clientId = client . getId ( ) ; List < UserSessionModel > userSessions = session . sessions ( ) . getUserSessions ( realm , user ) ; for ( UserSessionModel userSession : userSessions ) { List < ClientSessionModel > clientSessions = userSession . getClientSessions ( ) ; for ( ClientSessionModel clientSession : clientSessions ) { if ( clientSession . getClient ( ) . getId ( ) . equals ( clientId ) ) { AuthenticationManager . backchannelLogoutClientSession ( session , realm , clientSession , userSession , uriInfo , headers ) ; TokenManager . dettachClientSession ( session . sessions ( ) , realm , clientSession ) ; } } } }
Logout all clientSessions of this user and client
Logout all clientSessions of this user and client