Class NonceBackwardsCompatibleMapper
java.lang.Object
org.keycloak.protocol.oidc.mappers.NonceBackwardsCompatibleMapper
- All Implemented Interfaces:
OIDCAccessTokenMapper,ProtocolMapper,ConfiguredProvider,Provider,ProviderFactory<ProtocolMapper>
public class NonceBackwardsCompatibleMapper
extends Object
implements OIDCAccessTokenMapper, ProtocolMapper
Simple mapper that adds the nonce claim into the access token as before. Just adding the mapper reverts back to full old behavior in all the tokens (access, refresh and ID).
- Author:
- rmartinc
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()This is called when the server shuts down.static ProtocolMapperModelfinal ProtocolMappercreate(KeycloakSession session) getId()voidinit(Config.Scope config) Only called once when the factory is first created.voidpostInit(KeycloakSessionFactory factory) Called after all provider factories have been initializedtransformAccessToken(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.keycloak.provider.ConfiguredProvider
getConfigMethods inherited from interface org.keycloak.protocol.ProtocolMapper
getEffectiveModel, getPriority, validateConfigMethods inherited from interface org.keycloak.provider.ProviderFactory
dependsOn, getConfigMetadata, order
-
Field Details
-
PROVIDER_ID
- See Also:
-
-
Constructor Details
-
NonceBackwardsCompatibleMapper
public NonceBackwardsCompatibleMapper()
-
-
Method Details
-
getProtocol
- Specified by:
getProtocolin interfaceProtocolMapper
-
close
public void close()Description copied from interface:ProviderFactoryThis is called when the server shuts down.- Specified by:
closein interfaceProvider- Specified by:
closein interfaceProviderFactory<ProtocolMapper>
-
create
- Specified by:
createin interfaceProviderFactory<ProtocolMapper>
-
init
Description copied from interface:ProviderFactoryOnly called once when the factory is first created.- Specified by:
initin interfaceProviderFactory<ProtocolMapper>
-
postInit
Description copied from interface:ProviderFactoryCalled after all provider factories have been initialized- Specified by:
postInitin interfaceProviderFactory<ProtocolMapper>
-
getId
- Specified by:
getIdin interfaceProviderFactory<ProtocolMapper>
-
getDisplayType
- Specified by:
getDisplayTypein interfaceProtocolMapper
-
getDisplayCategory
- Specified by:
getDisplayCategoryin interfaceProtocolMapper
-
getHelpText
- Specified by:
getHelpTextin interfaceConfiguredProvider
-
getConfigProperties
- Specified by:
getConfigPropertiesin interfaceConfiguredProvider
-
transformAccessToken
public AccessToken transformAccessToken(AccessToken token, ProtocolMapperModel mappingModel, KeycloakSession session, UserSessionModel userSession, ClientSessionContext clientSessionCtx) - Specified by:
transformAccessTokenin interfaceOIDCAccessTokenMapper
-
create
-