Uses of Interface
org.keycloak.models.UserSessionModel
Package
Description
-
Uses of UserSessionModel in org.keycloak.authentication
Modifier and TypeMethodDescriptionstatic ClientSessionContext
AuthenticationProcessor.attachSession
(AuthenticationSessionModel authSession, UserSessionModel userSession, KeycloakSession session, RealmModel realm, ClientConnection connection, EventBuilder event) void
AuthenticationFlowContext.attachUserSession
(UserSessionModel userSession) void
AuthenticationProcessor.Result.attachUserSession
(UserSessionModel userSession) -
Uses of UserSessionModel in org.keycloak.authentication.authenticators.util
Modifier and TypeMethodDescriptionstatic void
AuthenticatorUtils.updateCompletedExecutions
(AuthenticationSessionModel authSession, UserSessionModel userSession, String executionId) Update the completed authenticators note on the new auth session -
Uses of UserSessionModel in org.keycloak.broker.oidc
Modifier and TypeMethodDescriptionvoid
OIDCIdentityProvider.backchannelLogout
(KeycloakSession session, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, RealmModel realm) protected void
OIDCIdentityProvider.backchannelLogout
(UserSessionModel userSession, String idToken) void
AbstractOAuth2IdentityProvider.exchangeExternalComplete
(UserSessionModel userSession, BrokeredIdentityContext context, jakarta.ws.rs.core.MultivaluedMap<String, String> params) jakarta.ws.rs.core.Response
AbstractOAuth2IdentityProvider.exchangeFromToken
(jakarta.ws.rs.core.UriInfo uriInfo, EventBuilder event, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject, jakarta.ws.rs.core.MultivaluedMap<String, String> params) protected jakarta.ws.rs.core.Response
AbstractOAuth2IdentityProvider.exchangeSessionToken
(jakarta.ws.rs.core.UriInfo uriInfo, EventBuilder event, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject) protected jakarta.ws.rs.core.Response
OIDCIdentityProvider.exchangeSessionToken
(jakarta.ws.rs.core.UriInfo uriInfo, EventBuilder event, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject) protected jakarta.ws.rs.core.Response
AbstractOAuth2IdentityProvider.exchangeStoredToken
(jakarta.ws.rs.core.UriInfo uriInfo, EventBuilder event, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject) protected jakarta.ws.rs.core.Response
OIDCIdentityProvider.exchangeStoredToken
(jakarta.ws.rs.core.UriInfo uriInfo, EventBuilder event, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject) protected jakarta.ws.rs.core.Response
AbstractOAuth2IdentityProvider.hasExternalExchangeToken
(EventBuilder event, UserSessionModel tokenUserSession, jakarta.ws.rs.core.MultivaluedMap<String, String> params) check to see if we have a token exchange in session in other words check to see if this session was created by an external exchangejakarta.ws.rs.core.Response
OIDCIdentityProvider.keycloakInitiatedBrowserLogout
(KeycloakSession session, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, RealmModel realm) OIDCIdentityProvider.refreshTokenForLogout
(KeycloakSession session, UserSessionModel userSession) Returns access token response as a string from a refresh token invocation on the remote OIDC broker -
Uses of UserSessionModel in org.keycloak.broker.provider
Modifier and TypeMethodDescriptionvoid
BrokeredIdentityContext.addSessionNotesToUserSession
(UserSessionModel userSession) void
AbstractIdentityProvider.backchannelLogout
(KeycloakSession session, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, RealmModel realm) void
IdentityProvider.backchannelLogout
(KeycloakSession session, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, RealmModel realm) protected jakarta.ws.rs.core.Response
AbstractIdentityProvider.exchangeErrorResponse
(jakarta.ws.rs.core.UriInfo uriInfo, ClientModel authorizedClient, UserSessionModel tokenUserSession, String errorCode, String reason) void
ExchangeExternalToken.exchangeExternalComplete
(UserSessionModel userSession, BrokeredIdentityContext context, jakarta.ws.rs.core.MultivaluedMap<String, String> params) jakarta.ws.rs.core.Response
ExchangeTokenToIdentityProviderToken.exchangeFromToken
(jakarta.ws.rs.core.UriInfo uriInfo, EventBuilder event, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject, jakarta.ws.rs.core.MultivaluedMap<String, String> params) jakarta.ws.rs.core.Response
AbstractIdentityProvider.exchangeNotLinked
(jakarta.ws.rs.core.UriInfo uriInfo, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject) jakarta.ws.rs.core.Response
AbstractIdentityProvider.exchangeNotLinkedNoStore
(jakarta.ws.rs.core.UriInfo uriInfo, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject) jakarta.ws.rs.core.Response
AbstractIdentityProvider.exchangeTokenExpired
(jakarta.ws.rs.core.UriInfo uriInfo, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject) protected String
AbstractIdentityProvider.getLinkingUrl
(jakarta.ws.rs.core.UriInfo uriInfo, ClientModel authorizedClient, UserSessionModel tokenUserSession) jakarta.ws.rs.core.Response
AbstractIdentityProvider.keycloakInitiatedBrowserLogout
(KeycloakSession session, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, RealmModel realm) jakarta.ws.rs.core.Response
IdentityProvider.keycloakInitiatedBrowserLogout
(KeycloakSession session, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, RealmModel realm) Called when a Keycloak application initiates a logout through the browser. -
Uses of UserSessionModel in org.keycloak.broker.saml
Modifier and TypeMethodDescriptionvoid
SAMLIdentityProvider.backchannelLogout
(KeycloakSession session, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, RealmModel realm) protected LogoutRequestType
SAMLIdentityProvider.buildLogoutRequest
(UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, RealmModel realm, String singleLogoutServiceUrl, SamlProtocolExtensionsAwareBuilder.NodeGenerator... extensions) jakarta.ws.rs.core.Response
SAMLIdentityProvider.keycloakInitiatedBrowserLogout
(KeycloakSession session, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, RealmModel realm) -
Uses of UserSessionModel in org.keycloak.device
Modifier and TypeMethodDescriptionstatic void
DeviceActivityManager.attachDevice
(UserSessionModel userSession, KeycloakSession session) Attaches a device to the givenuserSession
where the device information is obtained from theHttpHeaders.USER_AGENT
in the current request, if available.static DeviceRepresentation
DeviceActivityManager.getCurrentDevice
(UserSessionModel userSession) Returns the device information associated with the givenuserSession
. -
Uses of UserSessionModel in org.keycloak.events
-
Uses of UserSessionModel in org.keycloak.models
Modifier and TypeInterfaceDescriptioninterface
Hacked extension to UserSessionModel so that user id can be obtain directly soModifier and TypeMethodDescriptionUserSessionProvider.createOfflineUserSession
(UserSessionModel userSession) Newly created userSession won't contain attached AuthenticatedClientSessionsUserSessionProvider.createUserSession
(String id, RealmModel realm, UserModel user, String loginUsername, String ipAddress, String authMethod, boolean rememberMe, String brokerSessionId, String brokerUserId, UserSessionModel.SessionPersistenceState persistenceState) Creates a new user session with the given parameters.default UserSessionModel
UserSessionProvider.createUserSession
(RealmModel realm, UserModel user, String loginUsername, String ipAddress, String authMethod, boolean rememberMe, String brokerSessionId, String brokerUserId) Deprecated.UserSessionProvider.getOfflineUserSession
(RealmModel realm, String userSessionId) AuthenticatedClientSessionModel.getUserSession()
UserSessionProvider.getUserSession
(RealmModel realm, String id) UserSessionProvider.getUserSessionByBrokerSessionId
(RealmModel realm, String brokerSessionId) default UserSessionModel
UserSessionProvider.getUserSessionIfClientExists
(RealmModel realm, String userSessionId, boolean offline, String clientUUID) Returns theUserSessionModel
if the user session with IDuserSessionId
exist, and it has anAuthenticatedClientSessionModel
from aClientModel
with IDclientUUID
.UserSessionProvider.getUserSessionWithPredicate
(RealmModel realm, String id, boolean offline, Predicate<UserSessionModel> predicate) Return userSession of specified ID as long as the predicate passes.Modifier and TypeMethodDescriptionUserSessionProvider.getOfflineUserSessionByBrokerUserIdStream
(RealmModel realm, String brokerUserId) Obtains the offline user sessions associated with the user that matches the specifiedbrokerUserId
.UserSessionProvider.getOfflineUserSessionsStream
(RealmModel realm, ClientModel client, Integer firstResult, Integer maxResults) Obtains the offline user sessions associated with the specified client, starting from thefirstResult
and containing at mostmaxResults
.UserSessionProvider.getOfflineUserSessionsStream
(RealmModel realm, UserModel user) Obtains the offline user sessions associated with the specified user.UserSessionProvider.getUserSessionByBrokerUserIdStream
(RealmModel realm, String brokerUserId) Obtains the online user sessions associated with the user that matches the specifiedbrokerUserId
.UserSessionProvider.getUserSessionsStream
(RealmModel realm, ClientModel client) Obtains the online user sessions associated with the specified client.UserSessionProvider.getUserSessionsStream
(RealmModel realm, ClientModel client, Integer firstResult, Integer maxResults) Obtains the online user sessions associated with the specified client, starting from thefirstResult
and containing at mostmaxResults
.UserSessionProvider.getUserSessionsStream
(RealmModel realm, UserModel user) Obtains the online user sessions associated with the specified user.Modifier and TypeMethodDescriptionUserSessionProvider.createClientSession
(RealmModel realm, ClientModel client, UserSessionModel userSession) UserSessionProvider.createOfflineClientSession
(AuthenticatedClientSessionModel clientSession, UserSessionModel offlineUserSession) Will automatically attach newly created offline client session to the offlineUserSessionUserSessionProvider.createOfflineUserSession
(UserSessionModel userSession) Newly created userSession won't contain attached AuthenticatedClientSessionsUserSessionProvider.getClientSession
(UserSessionModel userSession, ClientModel client, String clientSessionId, boolean offline) default AuthenticatedClientSessionModel
UserSessionProvider.getClientSession
(UserSessionModel userSession, ClientModel client, UUID clientSessionId, boolean offline) Deprecated.void
UserSessionProvider.removeOfflineUserSession
(RealmModel realm, UserSessionModel userSession) Removes the attached clientSessions as wellvoid
UserSessionProvider.removeUserSession
(RealmModel realm, UserSessionModel session) This will remove attached ClientLoginSessionModels tooModifier and TypeMethodDescriptionUserSessionProvider.getUserSessionWithPredicate
(RealmModel realm, String id, boolean offline, Predicate<UserSessionModel> predicate) Return userSession of specified ID as long as the predicate passes.default void
UserSessionProvider.importUserSessions
(Collection<UserSessionModel> persistentUserSessions, boolean offline) Deprecated, for removal: This API element is subject to removal in a future version.Deprecated as offline session preloading was removed in KC25. -
Uses of UserSessionModel in org.keycloak.models.jpa.session
Modifier and TypeMethodDescriptionJpaUserSessionPersisterProvider.loadUserSession
(RealmModel realm, String userSessionId, boolean offline) JpaUserSessionPersisterProvider.loadUserSessionsStreamByBrokerSessionId
(RealmModel realm, String brokerSessionId, boolean offline) Modifier and TypeMethodDescriptionJpaUserSessionPersisterProvider.loadUserSessionsStream
(Integer firstResult, Integer maxResults, boolean offline, String lastUserSessionId) JpaUserSessionPersisterProvider.loadUserSessionsStream
(RealmModel realm, ClientModel client, boolean offline, Integer firstResult, Integer maxResults) JpaUserSessionPersisterProvider.loadUserSessionsStream
(RealmModel realm, UserModel user, boolean offline, Integer firstResult, Integer maxResults) Modifier and TypeMethodDescriptionvoid
JpaUserSessionPersisterProvider.createUserSession
(UserSessionModel userSession, boolean offline) JpaUserSessionPersisterProvider.loadClientSession
(RealmModel realm, ClientModel client, UserSessionModel userSession, boolean offline) -
Uses of UserSessionModel in org.keycloak.models.session
Modifier and TypeMethodDescriptionPersistentAuthenticatedClientSessionAdapter.getUserSession()
DisabledUserSessionPersisterProvider.loadUserSession
(RealmModel realm, String userSessionId, boolean offline) UserSessionPersisterProvider.loadUserSession
(RealmModel realm, String userSessionId, boolean offline) Loads the user session with the given userSessionId.default UserSessionModel
UserSessionPersisterProvider.loadUserSessionsStreamByBrokerSessionId
(RealmModel realm, String brokerSessionId, boolean offline) Modifier and TypeMethodDescriptionDisabledUserSessionPersisterProvider.loadUserSessionsStream
(Integer firstResult, Integer maxResults, boolean offline, String lastUserSessionId) DisabledUserSessionPersisterProvider.loadUserSessionsStream
(RealmModel realm, ClientModel client, boolean offline, Integer firstResult, Integer maxResults) DisabledUserSessionPersisterProvider.loadUserSessionsStream
(RealmModel realm, UserModel user, boolean offline, Integer firstResult, Integer maxResults) UserSessionPersisterProvider.loadUserSessionsStream
(Integer firstResult, Integer maxResults, boolean offline, String lastUserSessionId) Called during startup.UserSessionPersisterProvider.loadUserSessionsStream
(RealmModel realm, ClientModel client, boolean offline, Integer firstResult, Integer maxResults) Loads the user sessions for the givenClientModel
in the givenRealmModel
if present.UserSessionPersisterProvider.loadUserSessionsStream
(RealmModel realm, UserModel user, boolean offline, Integer firstResult, Integer maxResults) Loads the user sessions for the givenUserModel
in the givenRealmModel
if present.Modifier and TypeMethodDescriptionvoid
DisabledUserSessionPersisterProvider.createUserSession
(UserSessionModel userSession, boolean offline) void
UserSessionPersisterProvider.createUserSession
(UserSessionModel userSession, boolean offline) DisabledUserSessionPersisterProvider.loadClientSession
(RealmModel realm, ClientModel client, UserSessionModel userSession, boolean offline) UserSessionPersisterProvider.loadClientSession
(RealmModel realm, ClientModel client, UserSessionModel userSession, boolean offline) Loads client session from the db by provided user session and client.void
PersistentAuthenticatedClientSessionAdapter.setUserSession
(UserSessionModel userSession) ModifierConstructorDescriptionPersistentAuthenticatedClientSessionAdapter
(KeycloakSession session, PersistentClientSessionModel model, RealmModel realm, ClientModel client, UserSessionModel userSession) -
Uses of UserSessionModel in org.keycloak.models.sessions.infinispan
Modifier and TypeClassDescriptionclass
UserSessionAdapter<T extends SessionRefreshStore & UserSessionProvider>
Modifier and TypeMethodDescriptionInfinispanUserSessionProvider.createOfflineUserSession
(UserSessionModel userSession) PersistentUserSessionProvider.createOfflineUserSession
(UserSessionModel userSession) InfinispanUserSessionProvider.createUserSession
(String id, RealmModel realm, UserModel user, String loginUsername, String ipAddress, String authMethod, boolean rememberMe, String brokerSessionId, String brokerUserId, UserSessionModel.SessionPersistenceState persistenceState) PersistentUserSessionProvider.createUserSession
(String id, RealmModel realm, UserModel user, String loginUsername, String ipAddress, String authMethod, boolean rememberMe, String brokerSessionId, String brokerUserId, UserSessionModel.SessionPersistenceState persistenceState) AuthenticatedClientSessionAdapter.getUserSession()
InfinispanUserSessionProvider.getUserSession
(RealmModel realm, String id) PersistentUserSessionProvider.getUserSession
(RealmModel realm, String id) InfinispanUserSessionProvider.getUserSessionByBrokerSessionId
(RealmModel realm, String brokerSessionId) PersistentUserSessionProvider.getUserSessionByBrokerSessionId
(RealmModel realm, String brokerSessionId) InfinispanUserSessionProvider.getUserSessionWithPredicate
(RealmModel realm, String id, boolean offline, Predicate<UserSessionModel> predicate) PersistentUserSessionProvider.getUserSessionWithPredicate
(RealmModel realm, String id, boolean offline, Predicate<UserSessionModel> predicate) Modifier and TypeMethodDescriptionInfinispanUserSessionProvider.getOfflineUserSessionByBrokerUserIdStream
(RealmModel realm, String brokerUserId) PersistentUserSessionProvider.getOfflineUserSessionByBrokerUserIdStream
(RealmModel realm, String brokerUserId) InfinispanUserSessionProvider.getOfflineUserSessionsStream
(RealmModel realm, ClientModel client, Integer first, Integer max) InfinispanUserSessionProvider.getOfflineUserSessionsStream
(RealmModel realm, UserModel user) PersistentUserSessionProvider.getOfflineUserSessionsStream
(RealmModel realm, ClientModel client, Integer first, Integer max) PersistentUserSessionProvider.getOfflineUserSessionsStream
(RealmModel realm, UserModel user) InfinispanUserSessionProvider.getUserSessionByBrokerUserIdStream
(RealmModel realm, String brokerUserId) PersistentUserSessionProvider.getUserSessionByBrokerUserIdStream
(RealmModel realm, String brokerUserId) InfinispanUserSessionProvider.getUserSessionsStream
(RealmModel realm, ClientModel client) InfinispanUserSessionProvider.getUserSessionsStream
(RealmModel realm, ClientModel client, Integer firstResult, Integer maxResults) protected Stream<UserSessionModel>
InfinispanUserSessionProvider.getUserSessionsStream
(RealmModel realm, ClientModel client, Integer firstResult, Integer maxResults, boolean offline) protected Stream<UserSessionModel>
InfinispanUserSessionProvider.getUserSessionsStream
(RealmModel realm, UserSessionPredicate predicate, boolean offline) InfinispanUserSessionProvider.getUserSessionsStream
(RealmModel realm, UserModel user) PersistentUserSessionProvider.getUserSessionsStream
(RealmModel realm, ClientModel client) PersistentUserSessionProvider.getUserSessionsStream
(RealmModel realm, ClientModel client, Integer firstResult, Integer maxResults) protected Stream<UserSessionModel>
PersistentUserSessionProvider.getUserSessionsStream
(RealmModel realm, ClientModel client, Integer firstResult, Integer maxResults, boolean offline) protected Stream<UserSessionModel>
PersistentUserSessionProvider.getUserSessionsStream
(RealmModel realm, UserSessionPredicate predicate, boolean offline) PersistentUserSessionProvider.getUserSessionsStream
(RealmModel realm, UserModel user) Modifier and TypeMethodDescriptionInfinispanUserSessionProvider.createClientSession
(RealmModel realm, ClientModel client, UserSessionModel userSession) PersistentUserSessionProvider.createClientSession
(RealmModel realm, ClientModel client, UserSessionModel userSession) InfinispanUserSessionProvider.createOfflineClientSession
(AuthenticatedClientSessionModel clientSession, UserSessionModel offlineUserSession) PersistentUserSessionProvider.createOfflineClientSession
(AuthenticatedClientSessionModel clientSession, UserSessionModel offlineUserSession) InfinispanUserSessionProvider.createOfflineUserSession
(UserSessionModel userSession) PersistentUserSessionProvider.createOfflineUserSession
(UserSessionModel userSession) InfinispanUserSessionProvider.getClientSession
(UserSessionModel userSession, ClientModel client, String clientSessionId, boolean offline) PersistentUserSessionProvider.getClientSession
(UserSessionModel userSession, ClientModel client, String clientSessionId, boolean offline) protected UserSessionAdapter
InfinispanUserSessionProvider.importUserSession
(UserSessionModel userSession, boolean offline) PersistentUserSessionProvider.importUserSession
(UserSessionModel persistentUserSession, boolean offline) void
InfinispanUserSessionProvider.removeOfflineUserSession
(RealmModel realm, UserSessionModel userSession) void
PersistentUserSessionProvider.removeOfflineUserSession
(RealmModel realm, UserSessionModel userSession) void
InfinispanUserSessionProvider.removeUserSession
(RealmModel realm, UserSessionModel session) void
PersistentUserSessionProvider.removeUserSession
(RealmModel realm, UserSessionModel session) PersistentUserSessionProvider.wrapPersistentEntity
(RealmModel realm, boolean offline, UserSessionModel persistentUserSession) Modifier and TypeMethodDescriptionInfinispanUserSessionProvider.getUserSessionWithPredicate
(RealmModel realm, String id, boolean offline, Predicate<UserSessionModel> predicate) PersistentUserSessionProvider.getUserSessionWithPredicate
(RealmModel realm, String id, boolean offline, Predicate<UserSessionModel> predicate) void
InfinispanUserSessionProvider.importUserSessions
(Collection<UserSessionModel> persistentUserSessions, boolean offline) void
PersistentUserSessionProvider.importUserSessions
(Collection<UserSessionModel> persistentUserSessions, boolean offline) ModifierConstructorDescriptionAuthenticatedClientSessionAdapter
(KeycloakSession kcSession, SessionRefreshStore provider, AuthenticatedClientSessionEntity entity, ClientModel client, UserSessionModel userSession, SessionsChangelogBasedTransaction<UUID, AuthenticatedClientSessionEntity> clientSessionUpdateTx, boolean offline) -
Uses of UserSessionModel in org.keycloak.models.sessions.infinispan.changes
Modifier and TypeMethodDescriptionClientSessionPersistentChangelogBasedTransaction.get
(RealmModel realm, ClientModel client, UserSessionModel userSession, UUID key, boolean offline) UserSessionPersistentChangelogBasedTransaction.get
(RealmModel realm, String key, UserSessionModel userSession, boolean offline) -
Uses of UserSessionModel in org.keycloak.models.sessions.infinispan.changes.remote.updater.client
Modifier and TypeMethodDescriptionvoid
AuthenticatedClientSessionUpdater.initialize
(UserSessionModel userSession, ClientModel client, ClientSessionChangeLogTransaction clientTransaction) Initializes this class with references to other models classes. -
Uses of UserSessionModel in org.keycloak.models.sessions.infinispan.changes.remote.updater.user
Modifier and TypeClassDescriptionclass
TheUpdater
implementation to keep track of modifications forUserSessionModel
. -
Uses of UserSessionModel in org.keycloak.models.sessions.infinispan.changes.sessions
Modifier and TypeMethodDescriptionCrossDCLastSessionRefreshChecker.shouldSaveClientSessionToRemoteCache
(KeycloakSession kcSession, RealmModel realm, SessionEntityWrapper<AuthenticatedClientSessionEntity> sessionWrapper, UserSessionModel userSession, boolean offline, int newTimestamp) -
Uses of UserSessionModel in org.keycloak.models.sessions.infinispan.entities
Modifier and TypeMethodDescriptionAuthenticatedClientSessionEntity.create
(UUID clientSessionId, RealmModel realm, ClientModel client, UserSessionModel userSession) RemoteAuthenticatedClientSessionEntity.create
(ClientSessionKey id, String realmId, UserSessionModel userSession) static RemoteUserSessionEntity
RemoteUserSessionEntity.createFromModel
(UserSessionModel model) static UserSessionEntity
UserSessionEntity.createFromModel
(UserSessionModel userSession) -
Uses of UserSessionModel in org.keycloak.models.sessions.infinispan.remote
Modifier and TypeMethodDescriptionRemoteUserSessionProvider.createOfflineUserSession
(UserSessionModel userSession) RemoteUserSessionProvider.createUserSession
(String id, RealmModel realm, UserModel user, String loginUsername, String ipAddress, String authMethod, boolean rememberMe, String brokerSessionId, String brokerUserId, UserSessionModel.SessionPersistenceState persistenceState) RemoteUserSessionProvider.getOfflineUserSession
(RealmModel realm, String userSessionId) RemoteUserSessionProvider.getUserSession
(RealmModel realm, String id) RemoteUserSessionProvider.getUserSessionByBrokerSessionId
(RealmModel realm, String brokerSessionId) RemoteUserSessionProvider.getUserSessionWithPredicate
(RealmModel realm, String id, boolean offline, Predicate<UserSessionModel> predicate) Modifier and TypeMethodDescriptionRemoteUserSessionProvider.getOfflineUserSessionByBrokerUserIdStream
(RealmModel realm, String brokerUserId) RemoteUserSessionProvider.getOfflineUserSessionsStream
(RealmModel realm, ClientModel client, Integer firstResult, Integer maxResults) RemoteUserSessionProvider.getOfflineUserSessionsStream
(RealmModel realm, UserModel user) RemoteUserSessionProvider.getUserSessionByBrokerUserIdStream
(RealmModel realm, String brokerUserId) RemoteUserSessionProvider.getUserSessionsStream
(RealmModel realm, ClientModel client) RemoteUserSessionProvider.getUserSessionsStream
(RealmModel realm, ClientModel client, Integer firstResult, Integer maxResults) RemoteUserSessionProvider.getUserSessionsStream
(RealmModel realm, UserModel user) Modifier and TypeMethodDescriptionRemoteUserSessionProvider.createClientSession
(RealmModel realm, ClientModel client, UserSessionModel userSession) RemoteUserSessionProvider.createOfflineClientSession
(AuthenticatedClientSessionModel clientSession, UserSessionModel offlineUserSession) RemoteUserSessionProvider.createOfflineUserSession
(UserSessionModel userSession) RemoteUserSessionProvider.getClientSession
(UserSessionModel userSession, ClientModel client, String clientSessionId, boolean offline) void
RemoteUserSessionProvider.removeOfflineUserSession
(RealmModel realm, UserSessionModel userSession) void
RemoteUserSessionProvider.removeUserSession
(RealmModel realm, UserSessionModel userSession) Modifier and TypeMethodDescriptionRemoteUserSessionProvider.getUserSessionWithPredicate
(RealmModel realm, String id, boolean offline, Predicate<UserSessionModel> predicate) -
Uses of UserSessionModel in org.keycloak.models.sessions.infinispan.stream
Modifier and TypeMethodDescriptionPredicate<? super UserSessionModel>
UserSessionPredicate.toModelPredicate()
-
Uses of UserSessionModel in org.keycloak.models.utils
Modifier and TypeMethodDescriptionstatic UserSessionRepresentation
ModelToRepresentation.toRepresentation
(UserSessionModel session) -
Uses of UserSessionModel in org.keycloak.organization.protocol.mappers.oidc
Modifier and TypeMethodDescriptionprotected void
OrganizationMembershipMapper.setClaim
(IDToken token, ProtocolMapperModel model, UserSessionModel userSession, KeycloakSession session, ClientSessionContext clientSessionCtx) -
Uses of UserSessionModel in org.keycloak.organization.protocol.mappers.saml
Modifier and TypeMethodDescriptionvoid
OrganizationMembershipMapper.transformAttributeStatement
(AttributeStatementType attributeStatement, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) -
Uses of UserSessionModel in org.keycloak.protocol
Modifier and TypeMethodDescriptionjakarta.ws.rs.core.Response
LoginProtocol.authenticated
(AuthenticationSessionModel authSession, UserSessionModel userSession, ClientSessionContext clientSessionCtx) jakarta.ws.rs.core.Response
LoginProtocol.backchannelLogout
(UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) jakarta.ws.rs.core.Response
LoginProtocol.finishBrowserLogout
(UserSessionModel userSession, AuthenticationSessionModel logoutSession) This method is called when browser logout is going to be finished.jakarta.ws.rs.core.Response
LoginProtocol.frontchannelLogout
(UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) boolean
LoginProtocol.requireReauthentication
(UserSessionModel userSession, AuthenticationSessionModel authSession) -
Uses of UserSessionModel in org.keycloak.protocol.docker
Modifier and TypeMethodDescriptionjakarta.ws.rs.core.Response
DockerAuthV2Protocol.authenticated
(AuthenticationSessionModel authSession, UserSessionModel userSession, ClientSessionContext clientSessionCtx) jakarta.ws.rs.core.Response
DockerAuthV2Protocol.backchannelLogout
(UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) jakarta.ws.rs.core.Response
DockerAuthV2Protocol.finishBrowserLogout
(UserSessionModel userSession, AuthenticationSessionModel logoutSession) jakarta.ws.rs.core.Response
DockerAuthV2Protocol.frontchannelLogout
(UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) boolean
DockerAuthV2Protocol.requireReauthentication
(UserSessionModel userSession, AuthenticationSessionModel clientSession) -
Uses of UserSessionModel in org.keycloak.protocol.docker.mapper
Modifier and TypeMethodDescriptionAllowAllDockerProtocolMapper.transformDockerResponseToken
(DockerResponseToken responseToken, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) DockerAuthV2AttributeMapper.transformDockerResponseToken
(DockerResponseToken responseToken, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) -
Uses of UserSessionModel in org.keycloak.protocol.oid4vc.issuance.mappers
Modifier and TypeMethodDescriptionvoid
OID4VCContextMapper.setClaimsForCredential
(VerifiableCredential verifiableCredential, UserSessionModel userSessionModel) void
OID4VCIssuedAtTimeClaimMapper.setClaimsForCredential
(VerifiableCredential verifiableCredential, UserSessionModel userSessionModel) abstract void
OID4VCMapper.setClaimsForCredential
(VerifiableCredential verifiableCredential, UserSessionModel userSessionModel) Set the claims to credential, like f.e.void
OID4VCStaticClaimMapper.setClaimsForCredential
(VerifiableCredential verifiableCredential, UserSessionModel userSessionModel) void
OID4VCSubjectIdMapper.setClaimsForCredential
(VerifiableCredential verifiableCredential, UserSessionModel userSessionModel) void
OID4VCTargetRoleMapper.setClaimsForCredential
(VerifiableCredential verifiableCredential, UserSessionModel userSessionModel) void
OID4VCTypeMapper.setClaimsForCredential
(VerifiableCredential verifiableCredential, UserSessionModel userSessionModel) void
OID4VCUserAttributeMapper.setClaimsForCredential
(VerifiableCredential verifiableCredential, UserSessionModel userSessionModel) void
OID4VCContextMapper.setClaimsForSubject
(Map<String, Object> claims, UserSessionModel userSessionModel) void
OID4VCIssuedAtTimeClaimMapper.setClaimsForSubject
(Map<String, Object> claims, UserSessionModel userSessionModel) abstract void
OID4VCMapper.setClaimsForSubject
(Map<String, Object> claims, UserSessionModel userSessionModel) Set the claims to the credential subject.void
OID4VCStaticClaimMapper.setClaimsForSubject
(Map<String, Object> claims, UserSessionModel userSessionModel) void
OID4VCSubjectIdMapper.setClaimsForSubject
(Map<String, Object> claims, UserSessionModel userSessionModel) void
OID4VCTargetRoleMapper.setClaimsForSubject
(Map<String, Object> claims, UserSessionModel userSessionModel) void
OID4VCTypeMapper.setClaimsForSubject
(Map<String, Object> claims, UserSessionModel userSessionModel) void
OID4VCUserAttributeMapper.setClaimsForSubject
(Map<String, Object> claims, UserSessionModel userSessionModel) -
Uses of UserSessionModel in org.keycloak.protocol.oidc
Modifier and TypeMethodDescriptionTokenManager.getValidUserSessionIfTokenIsValid
(KeycloakSession session, RealmModel realm, AccessToken token, EventBuilder eventBuilder) Checks if the token is valid and return a valid user session.Modifier and TypeMethodDescriptionstatic ClientSessionContext
TokenManager.attachAuthenticationSession
(KeycloakSession session, UserSessionModel userSession, AuthenticationSessionModel authSession) jakarta.ws.rs.core.Response
OIDCLoginProtocol.authenticated
(AuthenticationSessionModel authSession, UserSessionModel userSession, ClientSessionContext clientSessionCtx) jakarta.ws.rs.core.Response
OIDCLoginProtocol.backchannelLogout
(UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) jakarta.ws.rs.core.Response
OIDCLoginProtocol.buildRedirectUri
(OIDCRedirectUriBuilder redirectUriBuilder, AuthenticationSessionModel authSession, UserSessionModel userSession, ClientSessionContext clientSessionCtx) this method can be used in extension-implementations to theOIDCLoginProtocol
to add additional parameters to the redirectUri after successful authentication and to store these e.g.jakarta.ws.rs.core.Response
OIDCLoginProtocol.buildRedirectUri
(OIDCRedirectUriBuilder redirectUriBuilder, AuthenticationSessionModel authSession, UserSessionModel userSession, ClientSessionContext clientSessionCtx, Exception ex, LoginProtocol.Error oidcError) this method can be used in extension-implementations to theOIDCLoginProtocol
to add additional parameters to the redirectUri after failed authenticationTokenManager.createClientAccessToken
(KeycloakSession session, RealmModel realm, ClientModel client, UserModel user, UserSessionModel userSession, ClientSessionContext clientSessionCtx) protected jakarta.ws.rs.core.Response
DefaultTokenExchangeProvider.exchangeClientToClient
(UserModel targetUser, UserSessionModel targetUserSession, AccessToken token, boolean disallowOnHolderOfTokenMismatch) protected jakarta.ws.rs.core.Response
DefaultTokenExchangeProvider.exchangeClientToOIDCClient
(UserModel targetUser, UserSessionModel targetUserSession, String requestedTokenType, ClientModel targetClient, String audience, String scope) protected jakarta.ws.rs.core.Response
DefaultTokenExchangeProvider.exchangeClientToSAML2Client
(UserModel targetUser, UserSessionModel targetUserSession, String requestedTokenType, ClientModel targetClient) protected jakarta.ws.rs.core.Response
DefaultTokenExchangeProvider.exchangeToIdentityProvider
(UserModel targetUser, UserSessionModel targetUserSession, String requestedIssuer) jakarta.ws.rs.core.Response
OIDCLoginProtocol.finishBrowserLogout
(UserSessionModel userSession, AuthenticationSessionModel logoutSession) jakarta.ws.rs.core.Response
OIDCLoginProtocol.frontchannelLogout
(UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) protected AccessToken
TokenManager.initToken
(RealmModel realm, ClientModel client, UserModel user, UserSessionModel session, ClientSessionContext clientSessionCtx, jakarta.ws.rs.core.UriInfo uriInfo) protected boolean
OIDCLoginProtocol.isAuthTimeExpired
(UserSessionModel userSession, AuthenticationSessionModel authSession) protected boolean
OIDCLoginProtocol.isReAuthRequiredForKcAction
(UserSessionModel userSession, AuthenticationSessionModel authSession) boolean
OIDCLoginProtocol.requireReauthentication
(UserSessionModel userSession, AuthenticationSessionModel authSession) TokenManager.responseBuilder
(RealmModel realm, ClientModel client, EventBuilder event, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AccessTokenIntrospectionProvider.transformAccessToken
(AccessToken token, UserSessionModel userSession) TokenManager.transformAccessToken
(KeycloakSession session, AccessToken token, UserSessionModel userSession, ClientSessionContext clientSessionCtx) TokenManager.transformAccessTokenResponse
(KeycloakSession session, AccessTokenResponse accessTokenResponse, UserSessionModel userSession, ClientSessionContext clientSessionCtx) TokenManager.transformIDToken
(KeycloakSession session, IDToken token, UserSessionModel userSession, ClientSessionContext clientSessionCtx) TokenManager.transformIntrospectionAccessToken
(KeycloakSession session, AccessToken token, UserSessionModel userSession, ClientSessionContext clientSessionCtx) TokenManager.transformUserInfoAccessToken
(KeycloakSession session, AccessToken token, UserSessionModel userSession, ClientSessionContext clientSessionCtx) ModifierConstructorDescriptionAccessTokenResponseBuilder
(RealmModel realm, ClientModel client, EventBuilder event, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) TokenValidation
(UserModel user, UserSessionModel userSession, ClientSessionContext clientSessionCtx, AccessToken newToken) -
Uses of UserSessionModel in org.keycloak.protocol.oidc.grants
Modifier and TypeMethodDescriptionprotected jakarta.ws.rs.core.Response
OAuth2GrantTypeBase.createTokenResponse
(UserModel user, UserSessionModel userSession, ClientSessionContext clientSessionCtx, String scopeParam, boolean code, Function<TokenManager.AccessTokenResponseBuilder, ClientPolicyContext> clientPolicyContextGenerator) protected void
OAuth2GrantTypeBase.updateUserSessionFromClientAuth
(UserSessionModel userSession) -
Uses of UserSessionModel in org.keycloak.protocol.oidc.mappers
Modifier and TypeMethodDescriptionprotected void
AbstractOIDCProtocolMapper.setClaim
(AccessTokenResponse accessTokenResponse, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) Intended to be overridden inProtocolMapper
implementations to add claims to an token.protected void
AbstractOIDCProtocolMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession) protected void
AbstractOIDCProtocolMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) Intended to be overridden inProtocolMapper
implementations to add claims to an token.protected void
AcrProtocolMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
AddressMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession) protected void
AmrProtocolMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
AudienceProtocolMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
ClaimsParameterTokenMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
ClaimsParameterWithValueIdTokenMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
FullNameMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession) protected void
GroupMembershipMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession) Adds the group membership information to theJsonWebToken.otherClaims
.protected void
HardcodedClaim.setClaim
(AccessTokenResponse accessTokenResponse, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
HardcodedClaim.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession) protected void
HardcodedRole.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession session, ClientSessionContext clientSessionCtx) protected void
RoleNameMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession session, ClientSessionContext clientSessionCtx) protected void
ScriptBasedOIDCProtocolMapper.setClaim
(AccessTokenResponse accessTokenResponse, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
ScriptBasedOIDCProtocolMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
SessionStateMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
SubMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
UserAttributeMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession) protected void
UserClientRoleMappingMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession session, ClientSessionContext clientSessionCtx) protected void
UserPropertyMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession) protected void
UserRealmRoleMappingMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession session, ClientSessionContext clientSessionCtx) protected void
UserSessionNoteMapper.setClaim
(AccessTokenResponse accessTokenResponse, ProtocolMapperModel mappingModel, UserSessionModel userSession, KeycloakSession keycloakSession, ClientSessionContext clientSessionCtx) protected void
UserSessionNoteMapper.setClaim
(IDToken token, ProtocolMapperModel mappingModel, UserSessionModel userSession) AbstractOIDCProtocolMapper.transformAccessToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AbstractPairwiseSubMapper.transformAccessToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AllowedWebOriginsProtocolMapper.transformAccessToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AudienceResolveProtocolMapper.transformAccessToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) HardcodedRole.transformAccessToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) NonceBackwardsCompatibleMapper.transformAccessToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) OIDCAccessTokenMapper.transformAccessToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) RoleNameMapper.transformAccessToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AbstractOIDCProtocolMapper.transformAccessTokenResponse
(AccessTokenResponse accessTokenResponse, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) OIDCAccessTokenResponseMapper.transformAccessTokenResponse
(AccessTokenResponse accessTokenResponse, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AbstractOIDCProtocolMapper.transformIDToken
(IDToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AbstractPairwiseSubMapper.transformIDToken
(IDToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) OIDCIDTokenMapper.transformIDToken
(IDToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSession) AbstractOIDCProtocolMapper.transformIntrospectionToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AbstractPairwiseSubMapper.transformIntrospectionToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AllowedWebOriginsProtocolMapper.transformIntrospectionToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AudienceResolveProtocolMapper.transformIntrospectionToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) HardcodedRole.transformIntrospectionToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) RoleNameMapper.transformIntrospectionToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) TokenIntrospectionTokenMapper.transformIntrospectionToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AbstractOIDCProtocolMapper.transformUserInfoToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) AbstractPairwiseSubMapper.transformUserInfoToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) HardcodedRole.transformUserInfoToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) RoleNameMapper.transformUserInfoToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) UserInfoTokenMapper.transformUserInfoToken
(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) -
Uses of UserSessionModel in org.keycloak.protocol.saml
Modifier and TypeMethodDescriptionjakarta.ws.rs.core.Response
SamlProtocol.authenticated
(AuthenticationSessionModel authSession, UserSessionModel userSession, ClientSessionContext clientSessionCtx) jakarta.ws.rs.core.Response
SamlProtocol.backchannelLogout
(UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) protected String
SamlProtocol.buildArtifactAndStoreResponse
(SAML2Object statusResponseType, UserSessionModel userSession) protected jakarta.ws.rs.core.Response
SamlProtocol.buildLogoutArtifactResponse
(UserSessionModel userSession, String redirectUri, StatusResponseType statusResponseType, JaxrsSAML2BindingBuilder bindingBuilder) This method, instead of sending the actual response with the token, sends the artifact message via post or redirect.protected jakarta.ws.rs.core.Response
SamlProtocol.buildLogoutResponse
(UserSessionModel userSession, String logoutBindingUri, SAML2LogoutResponseBuilder builder, JaxrsSAML2BindingBuilder binding) jakarta.ws.rs.core.Response
SamlProtocol.finishBrowserLogout
(UserSessionModel userSession, AuthenticationSessionModel logoutSession) jakarta.ws.rs.core.Response
SamlProtocol.frontchannelLogout
(UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) protected String
SamlProtocol.getNameId
(String nameIdFormat, CommonClientSessionModel clientSession, UserSessionModel userSession) protected String
SamlProtocol.getPersistentNameId
(CommonClientSessionModel clientSession, UserSessionModel userSession) Attempts to retrieve the persistent type NameId as follows: saml.persistent.name.id.for.$clientId user attribute saml.persistent.name.id.for.* user attribute G-$randomUuidprotected String
SamlProtocol.getSAMLNameId
(List<SamlProtocol.ProtocolMapperProcessor<SAMLNameIdMapper>> samlNameIdMappers, String nameIdFormat, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) static boolean
SamlProtocol.isLogoutPostBindingForInitiator
(UserSessionModel session) SamlProtocol.populateAttributeStatements
(List<SamlProtocol.ProtocolMapperProcessor<SAMLAttributeStatementMapper>> attributeStatementMappers, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) void
SamlProtocol.populateRoles
(SamlProtocol.ProtocolMapperProcessor<SAMLRoleListMapper> roleListMapper, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx, AttributeStatementType existingAttributeStatement) boolean
SamlProtocol.requireReauthentication
(UserSessionModel userSession, AuthenticationSessionModel authSession) SamlProtocol.transformLoginResponse
(List<SamlProtocol.ProtocolMapperProcessor<SAMLLoginResponseMapper>> mappers, ResponseType response, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) -
Uses of UserSessionModel in org.keycloak.protocol.saml.mappers
Modifier and TypeMethodDescriptionSAMLNameIdMapper.mapperNameId
(String nameIdFormat, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) UserAttributeNameIdMapper.mapperNameId
(String nameIdFormat, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) void
RoleListMapper.mapRoles
(AttributeStatementType roleAttributeStatement, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) void
SAMLRoleListMapper.mapRoles
(AttributeStatementType roleAttributeStatement, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) void
GroupMembershipMapper.transformAttributeStatement
(AttributeStatementType attributeStatement, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) void
HardcodedAttributeMapper.transformAttributeStatement
(AttributeStatementType attributeStatement, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) void
SAMLAttributeStatementMapper.transformAttributeStatement
(AttributeStatementType attributeStatement, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) void
ScriptBasedMapper.transformAttributeStatement
(AttributeStatementType attributeStatement, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) This method attaches one or many attributes to the passed attribute statement.void
UserAttributeStatementMapper.transformAttributeStatement
(AttributeStatementType attributeStatement, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) void
UserPropertyAttributeStatementMapper.transformAttributeStatement
(AttributeStatementType attributeStatement, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) void
UserSessionNoteStatementMapper.transformAttributeStatement
(AttributeStatementType attributeStatement, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) SAMLAudienceProtocolMapper.transformLoginResponse
(ResponseType response, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) SAMLAudienceResolveProtocolMapper.transformLoginResponse
(ResponseType response, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) SAMLLoginResponseMapper.transformLoginResponse
(ResponseType response, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) -
Uses of UserSessionModel in org.keycloak.protocol.saml.preprocessor
Modifier and TypeMethodDescriptiondefault LogoutRequestType
SamlAuthenticationPreprocessor.beforeProcessingLogoutRequest
(LogoutRequestType logoutRequest, UserSessionModel authSession, AuthenticatedClientSessionModel clientSession) Called before a logout request is processed.default LogoutRequestType
SamlAuthenticationPreprocessor.beforeSendingLogoutRequest
(LogoutRequestType logoutRequest, UserSessionModel authSession, AuthenticatedClientSessionModel clientSession) Called before a logout request is sent. -
Uses of UserSessionModel in org.keycloak.services.managers
Modifier and TypeMethodDescriptionUserSessionManager.createUserSession
(String id, RealmModel realm, UserModel user, String loginUsername, String ipAddress, String authMethod, boolean rememberMe, String brokerSessionId, String brokerUserId, UserSessionModel.SessionPersistenceState persistenceState) UserSessionManager.createUserSession
(RealmModel realm, UserModel user, String loginUsername, String ipAddress, String authMethod, boolean rememberMe, String brokerSessionId, String brokerUserId) UserSessionManager.findOfflineUserSession
(RealmModel realm, String userSessionId) Auth.getSession()
AuthenticationManager.AuthResult.getSession()
AuthenticationSessionManager.getUserSession
(AuthenticationSessionModel authSession) AuthenticationSessionManager.getUserSessionFromAuthenticationCookie
(RealmModel realm) UserSessionCrossDCManager.getUserSessionIfExistsRemotely
(AuthenticationSessionManager asm, RealmModel realm) Deprecated, for removal: This API element is subject to removal in a future version.To be removed in Keycloak 27+.UserSessionCrossDCManager.getUserSessionWithClient
(RealmModel realm, String id, boolean offline, String clientUUID) Deprecated, for removal: This API element is subject to removal in a future version.To be removed in Keycloak 27+.UserSessionCrossDCManager.getUserSessionWithClient
(RealmModel realm, String id, String clientUUID) Deprecated, for removal: This API element is subject to removal in a future version.To be removed in Keycloak 27+.UserSessionCrossDCManager.getUserSessionWithImpersonatorClient
(RealmModel realm, String id, boolean offline, String clientUUID) Deprecated, for removal: This API element is subject to removal in a future version.To be removed in Keycloak 27+.Modifier and TypeMethodDescriptionUserSessionManager.findOfflineSessions
(RealmModel realm, UserModel user) Deprecated.UserSessionManager.findOfflineSessionsStream
(RealmModel realm, UserModel user) Modifier and TypeMethodDescriptionstatic BackchannelLogoutResponse
AuthenticationManager.backchannelLogout
(KeycloakSession session, RealmModel realm, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, ClientConnection connection, jakarta.ws.rs.core.HttpHeaders headers, boolean logoutBroker) static BackchannelLogoutResponse
AuthenticationManager.backchannelLogout
(KeycloakSession session, RealmModel realm, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, ClientConnection connection, jakarta.ws.rs.core.HttpHeaders headers, boolean logoutBroker, boolean offlineSession) static void
AuthenticationManager.backchannelLogout
(KeycloakSession session, UserSessionModel userSession, boolean logoutBroker) static jakarta.ws.rs.core.Response
AuthenticationManager.browserLogout
(KeycloakSession session, RealmModel realm, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, ClientConnection connection, jakarta.ws.rs.core.HttpHeaders headers) static IdentityCookieToken
AuthenticationManager.createIdentityToken
(KeycloakSession keycloakSession, RealmModel realm, UserModel user, UserSessionModel session, String issuer) static void
AuthenticationManager.createLoginCookie
(KeycloakSession keycloakSession, RealmModel realm, UserModel user, UserSessionModel session, jakarta.ws.rs.core.UriInfo uriInfo, ClientConnection connection) static AuthenticationSessionModel
AuthenticationManager.createOrJoinLogoutSession
(KeycloakSession session, RealmModel realm, AuthenticationSessionManager asm, UserSessionModel userSession, boolean browserCookie, boolean initiateLogout) void
UserSessionManager.createOrUpdateOfflineSession
(AuthenticatedClientSessionModel clientSession, UserSessionModel userSession) static boolean
AuthenticationManager.expireUserSessionCookie
(KeycloakSession session, UserSessionModel userSession, RealmModel realm, jakarta.ws.rs.core.UriInfo uriInfo, jakarta.ws.rs.core.HttpHeaders headers, ClientConnection connection) static jakarta.ws.rs.core.Response
AuthenticationManager.finishBrowserLogout
(KeycloakSession session, RealmModel realm, UserSessionModel userSession, jakarta.ws.rs.core.UriInfo uriInfo, ClientConnection connection, jakarta.ws.rs.core.HttpHeaders headers) static jakarta.ws.rs.core.Response
AuthenticationManager.finishedRequiredActions
(KeycloakSession session, AuthenticationSessionModel authSession, UserSessionModel userSession, ClientConnection clientConnection, HttpRequest request, jakarta.ws.rs.core.UriInfo uriInfo, EventBuilder event) static void
AuthenticationManager.finishUnconfirmedUserSession
(KeycloakSession session, RealmModel realm, UserSessionModel userSessionModel) static boolean
AuthenticationManager.isClientSessionValid
(RealmModel realm, ClientModel client, UserSessionModel userSession, AuthenticatedClientSessionModel clientSession) static boolean
AuthenticationManager.isSessionValid
(RealmModel realm, UserSessionModel userSession) static jakarta.ws.rs.core.Response
AuthenticationManager.redirectAfterSuccessfulFlow
(KeycloakSession session, RealmModel realm, UserSessionModel userSession, ClientSessionContext clientSessionCtx, HttpRequest request, jakarta.ws.rs.core.UriInfo uriInfo, ClientConnection clientConnection, EventBuilder event, AuthenticationSessionModel authSession) static jakarta.ws.rs.core.Response
AuthenticationManager.redirectAfterSuccessfulFlow
(KeycloakSession session, RealmModel realm, UserSessionModel userSession, ClientSessionContext clientSessionCtx, HttpRequest request, jakarta.ws.rs.core.UriInfo uriInfo, ClientConnection clientConnection, EventBuilder event, AuthenticationSessionModel authSession, LoginProtocol protocol) void
UserSessionManager.revokeOfflineUserSession
(UserSessionModel userSession) ModifierConstructorDescriptionAuth
(RealmModel realm, AccessToken token, UserModel user, ClientModel client, UserSessionModel session, boolean cookie) AuthResult
(UserModel user, UserSessionModel session, AccessToken token, ClientModel client) -
Uses of UserSessionModel in org.keycloak.services.util
Modifier and TypeMethodDescriptionstatic UserSessionModel
UserSessionUtil.findValidSession
(KeycloakSession session, RealmModel realm, AccessToken token, EventBuilder event, ClientModel client) static UserSessionModel
UserSessionUtil.findValidSession
(KeycloakSession session, RealmModel realm, AccessToken token, EventBuilder event, ClientModel client, OAuth2Error error) static UserSessionModel
UserSessionUtil.getUserSessionWithImpersonatorClient
(KeycloakSession session, RealmModel realm, String userSessionId, boolean offline, String clientUUID) Modifier and TypeMethodDescriptionstatic void
UserSessionUtil.checkTokenIssuedAt
(RealmModel realm, AccessToken token, UserSessionModel userSession, EventBuilder event, ClientModel client) -
Uses of UserSessionModel in org.keycloak.social.twitter
Modifier and TypeMethodDescriptionjakarta.ws.rs.core.Response
TwitterIdentityProvider.exchangeFromToken
(jakarta.ws.rs.core.UriInfo uriInfo, EventBuilder builder, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject, jakarta.ws.rs.core.MultivaluedMap<String, String> params) protected jakarta.ws.rs.core.Response
TwitterIdentityProvider.exchangeSessionToken
(jakarta.ws.rs.core.UriInfo uriInfo, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject) protected jakarta.ws.rs.core.Response
TwitterIdentityProvider.exchangeStoredToken
(jakarta.ws.rs.core.UriInfo uriInfo, ClientModel authorizedClient, UserSessionModel tokenUserSession, UserModel tokenSubject)
UserSessionProvider.createUserSession(String, RealmModel, UserModel, String, String, String, boolean, String, String, UserSessionModel.SessionPersistenceState)
instead.