Class ReactiveOidcIdTokenDecoderFactory
- java.lang.Object
-
- org.springframework.security.oauth2.client.oidc.authentication.ReactiveOidcIdTokenDecoderFactory
-
- All Implemented Interfaces:
ReactiveJwtDecoderFactory<ClientRegistration>
public final class ReactiveOidcIdTokenDecoderFactory extends java.lang.Object implements ReactiveJwtDecoderFactory<ClientRegistration>
Afactorythat provides aReactiveJwtDecoderused forOidcIdTokensignature verification. The providedReactiveJwtDecoderis associated to a specificClientRegistration.- Since:
- 5.2
- See Also:
ReactiveJwtDecoderFactory,ClientRegistration,OidcIdToken
-
-
Constructor Summary
Constructors Constructor Description ReactiveOidcIdTokenDecoderFactory()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ReactiveJwtDecodercreateDecoder(ClientRegistration clientRegistration)Creates aReactiveJwtDecoderusing the supplied "contextual" type.static java.util.Map<java.lang.String,org.springframework.core.convert.converter.Converter<java.lang.Object,?>>createDefaultClaimTypeConverters()Returns the defaultConverter's used for type conversion of claim values for anOidcIdToken.voidsetClaimTypeConverterFactory(java.util.function.Function<ClientRegistration,org.springframework.core.convert.converter.Converter<java.util.Map<java.lang.String,java.lang.Object>,java.util.Map<java.lang.String,java.lang.Object>>> claimTypeConverterFactory)Sets the factory that provides aConverterused for type conversion of claim values for anOidcIdToken.voidsetJwsAlgorithmResolver(java.util.function.Function<ClientRegistration,JwsAlgorithm> jwsAlgorithmResolver)Sets the resolver that provides the expectedJWS algorithmused for the signature or MAC on theID Token.voidsetJwtValidatorFactory(java.util.function.Function<ClientRegistration,OAuth2TokenValidator<Jwt>> jwtValidatorFactory)Sets the factory that provides anOAuth2TokenValidator, which is used by theReactiveJwtDecoder.
-
-
-
Method Detail
-
createDefaultClaimTypeConverters
public static java.util.Map<java.lang.String,org.springframework.core.convert.converter.Converter<java.lang.Object,?>> createDefaultClaimTypeConverters()
Returns the defaultConverter's used for type conversion of claim values for anOidcIdToken.- Returns:
- a
MapofConverter's keyed byclaim name
-
createDecoder
public ReactiveJwtDecoder createDecoder(ClientRegistration clientRegistration)
Description copied from interface:ReactiveJwtDecoderFactoryCreates aReactiveJwtDecoderusing the supplied "contextual" type.- Specified by:
createDecoderin interfaceReactiveJwtDecoderFactory<ClientRegistration>- Parameters:
clientRegistration- the type that provides contextual information- Returns:
- a
ReactiveJwtDecoder
-
setJwtValidatorFactory
public void setJwtValidatorFactory(java.util.function.Function<ClientRegistration,OAuth2TokenValidator<Jwt>> jwtValidatorFactory)
Sets the factory that provides anOAuth2TokenValidator, which is used by theReactiveJwtDecoder. The default composesJwtTimestampValidatorandOidcIdTokenValidator.- Parameters:
jwtValidatorFactory- the factory that provides anOAuth2TokenValidator
-
setJwsAlgorithmResolver
public void setJwsAlgorithmResolver(java.util.function.Function<ClientRegistration,JwsAlgorithm> jwsAlgorithmResolver)
Sets the resolver that provides the expectedJWS algorithmused for the signature or MAC on theID Token. The default resolves toRS256for allclients.- Parameters:
jwsAlgorithmResolver- the resolver that provides the expectedJWS algorithmfor a specificclient
-
setClaimTypeConverterFactory
public void setClaimTypeConverterFactory(java.util.function.Function<ClientRegistration,org.springframework.core.convert.converter.Converter<java.util.Map<java.lang.String,java.lang.Object>,java.util.Map<java.lang.String,java.lang.Object>>> claimTypeConverterFactory)
Sets the factory that provides aConverterused for type conversion of claim values for anOidcIdToken. The default isClaimTypeConverterfor allclients.- Parameters:
claimTypeConverterFactory- the factory that provides aConverterused for type conversion of claim values for a specificclient
-
-