Class DefaultComputeAuthorizationCodeHashFunction
java.lang.Object
net.shibboleth.shared.component.AbstractInitializableComponent
net.shibboleth.shared.component.AbstractIdentifiedInitializableComponent
net.shibboleth.shared.component.AbstractIdentifiableInitializableComponent
net.shibboleth.idp.plugin.oidc.op.profile.context.navigate.DefaultComputeAuthorizationCodeHashFunction
- All Implemented Interfaces:
Function<ProfileRequestContext,,String> Component,DestructableComponent,IdentifiableComponent,IdentifiedComponent,InitializableComponent,ContextDataLookupFunction<ProfileRequestContext,String>
public class DefaultComputeAuthorizationCodeHashFunction
extends AbstractIdentifiableInitializableComponent
implements ContextDataLookupFunction<ProfileRequestContext,String>
A function that computes a hash value for the authorization code via required configurable lookup function.
The signature signing algorithm found in the
SecurityParametersContext is used for calculating the hash.
The lookup function for the security parameters context is required to be set.- Since:
- 3.2.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Function<ProfileRequestContext,String> Strategy used to locate the raw authorization code value (asString) to use for calculating the hash.private org.slf4j.LoggerClass logger.Strategy used to locate theSecurityParametersContextto use for calculating the code hash. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionapply(ProfileRequestContext input) protected voidvoidSet the strategy used to locate the authorization code value.voidsetSecurityParametersLookupStrategy(Function<ProfileRequestContext, SecurityParametersContext> strategy) Set the strategy used to locate theSecurityParametersContextto use.Methods inherited from class net.shibboleth.shared.component.AbstractIdentifiableInitializableComponent
setIdMethods inherited from class net.shibboleth.shared.component.AbstractIdentifiedInitializableComponent
ensureId, getId, ifDestroyedThrowDestroyedComponentException, ifInitializedThrowUnmodifiabledComponentException, ifNotInitializedThrowUninitializedComponentExceptionMethods inherited from class net.shibboleth.shared.component.AbstractInitializableComponent
checkComponentActive, checkSetterPreconditions, destroy, doDestroy, initialize, isDestroyed, isInitializedMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.shibboleth.shared.component.IdentifiedComponent
getId
-
Field Details
-
log
@Nonnull private org.slf4j.Logger logClass logger. -
securityParametersLookupStrategy
@NonnullAfterInit private Function<ProfileRequestContext,SecurityParametersContext> securityParametersLookupStrategyStrategy used to locate theSecurityParametersContextto use for calculating the code hash. -
authorizationCodeLookupStrategy
Strategy used to locate the raw authorization code value (asString) to use for calculating the hash.
-
-
Constructor Details
-
DefaultComputeAuthorizationCodeHashFunction
public DefaultComputeAuthorizationCodeHashFunction()
-
-
Method Details
-
setSecurityParametersLookupStrategy
public void setSecurityParametersLookupStrategy(@Nonnull Function<ProfileRequestContext, SecurityParametersContext> strategy) Set the strategy used to locate theSecurityParametersContextto use.- Parameters:
strategy- lookup strategy
-
setAuthorizationCodeLookupStrategy
public void setAuthorizationCodeLookupStrategy(@Nonnull Function<ProfileRequestContext, String> strategy) Set the strategy used to locate the authorization code value.- Parameters:
strategy- lookup strategy
-
doInitialize
- Overrides:
doInitializein classAbstractIdentifiedInitializableComponent- Throws:
ComponentInitializationException
-
apply
- Specified by:
applyin interfaceFunction<ProfileRequestContext,String>
-