Class InitializeRegistrationMetadataPolicyContext
java.lang.Object
net.shibboleth.shared.component.AbstractInitializableComponent
org.opensaml.profile.action.AbstractProfileAction
org.opensaml.profile.action.AbstractConditionalProfileAction
net.shibboleth.idp.profile.AbstractProfileAction
net.shibboleth.idp.plugin.oidc.op.profile.impl.InitializeRegistrationMetadataPolicyContext
- All Implemented Interfaces:
Component,DestructableComponent,InitializableComponent,ProfileAction,Aware,MessageSource,MessageSourceAware,Action
Initializes the
OIDCClientRegistrationMetadataPolicyContext and attaches it as a subcontext for the incoming
MessageContext. The context contains the merged metadata policy, containing the policy items defined in the
profile configuration and initial registration access token (if involved).-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final org.slf4j.LoggerClass logger.The metadata policy context to operate on.private BiFunction<Map<String,MetadataPolicy>, Map<String, MetadataPolicy>, Pair<Map<String, MetadataPolicy>, Boolean>> The strategy used for merging profile and token based metadata policies.private Predicate<Map<String,MetadataPolicy>> The strategy used for validating token and merged metadata policies.private Function<ProfileRequestContext,Map<String, MetadataPolicy>> The strategy used to locate the request metadata policy configured for the profile.The strategy used to create or locate the metadata policy context.private Function<ProfileRequestContext,Map<String, MetadataPolicy>> The strategy used to locate the request metadata policy encoded in the access token. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voiddoExecute(ProfileRequestContext profileRequestContext) protected voidprotected booleandoPreExecute(ProfileRequestContext profileRequestContext) voidsetMetadataPolicyMergingStrategy(BiFunction<Map<String, MetadataPolicy>, Map<String, MetadataPolicy>, Pair<Map<String, MetadataPolicy>, Boolean>> strategy) Set the strategy used for merging profile and token based metadata policies.voidSet the strategy used for validating token and merged metadata policies.voidsetProfileMetadataPolicyLookupStrategy(Function<ProfileRequestContext, Map<String, MetadataPolicy>> strategy) Set the strategy used to locate the request metadata policy configured for the profile.voidsetRegistrationPolicyContextCreationStrategy(Function<ProfileRequestContext, OIDCClientRegistrationMetadataPolicyContext> strategy) Set the strategy used to create or return theOIDCClientRegistrationMetadataPolicyContext.voidsetTokenMetadataPolicyLookupStrategy(Function<ProfileRequestContext, Map<String, MetadataPolicy>> strategy) Set the strategy used to locate the request metadata policy encoded in the access token.Methods inherited from class net.shibboleth.idp.profile.AbstractProfileAction
doExecute, execute, getBean, getBean, getMessage, getMessage, getMessage, getParameter, getParameter, getProfileContextLookupStrategy, getRequestContext, getResult, setMessageSource, setProfileContextLookupStrategyMethods inherited from class org.opensaml.profile.action.AbstractConditionalProfileAction
getActivationCondition, setActivationConditionMethods inherited from class org.opensaml.profile.action.AbstractProfileAction
doPostExecute, doPostExecute, ensureHttpServletRequest, ensureHttpServletResponse, execute, getHttpServletRequest, getHttpServletRequestSupplier, getHttpServletResponse, getHttpServletResponseSupplier, getLogPrefix, isPreExecuteCalled, setHttpServletRequestSupplier, setHttpServletResponseSupplierMethods inherited from class net.shibboleth.shared.component.AbstractInitializableComponent
checkComponentActive, checkSetterPreconditions, destroy, doDestroy, ifDestroyedThrowDestroyedComponentException, ifInitializedThrowUnmodifiabledComponentException, ifNotInitializedThrowUninitializedComponentException, 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.InitializableComponent
initialize, isInitialized
-
Field Details
-
log
@Nonnull private final org.slf4j.Logger logClass logger. -
profileMetadataPolicyLookupStrategy
@Nonnull private Function<ProfileRequestContext,Map<String, profileMetadataPolicyLookupStrategyMetadataPolicy>> The strategy used to locate the request metadata policy configured for the profile. -
tokenMetadataPolicyLookupStrategy
@Nonnull private Function<ProfileRequestContext,Map<String, tokenMetadataPolicyLookupStrategyMetadataPolicy>> The strategy used to locate the request metadata policy encoded in the access token. -
registrationPolicyContextCreationStrategy
@Nonnull private Function<ProfileRequestContext,OIDCClientRegistrationMetadataPolicyContext> registrationPolicyContextCreationStrategyThe strategy used to create or locate the metadata policy context. -
metadataPolicyMergingStrategy
@Nonnull private BiFunction<Map<String,MetadataPolicy>, metadataPolicyMergingStrategyMap<String, MetadataPolicy>, Pair<Map<String, MetadataPolicy>, Boolean>> The strategy used for merging profile and token based metadata policies. -
metadataPolicyValidationStrategy
The strategy used for validating token and merged metadata policies. -
metadataPolicyContext
The metadata policy context to operate on.
-
-
Constructor Details
-
InitializeRegistrationMetadataPolicyContext
public InitializeRegistrationMetadataPolicyContext()Constructor.
-
-
Method Details
-
setProfileMetadataPolicyLookupStrategy
public void setProfileMetadataPolicyLookupStrategy(@Nonnull Function<ProfileRequestContext, Map<String, MetadataPolicy>> strategy) Set the strategy used to locate the request metadata policy configured for the profile.- Parameters:
strategy- What to set.
-
setTokenMetadataPolicyLookupStrategy
public void setTokenMetadataPolicyLookupStrategy(@Nonnull Function<ProfileRequestContext, Map<String, MetadataPolicy>> strategy) Set the strategy used to locate the request metadata policy encoded in the access token.- Parameters:
strategy- What to set.
-
setRegistrationPolicyContextCreationStrategy
public void setRegistrationPolicyContextCreationStrategy(@Nonnull Function<ProfileRequestContext, OIDCClientRegistrationMetadataPolicyContext> strategy) Set the strategy used to create or return theOIDCClientRegistrationMetadataPolicyContext.- Parameters:
strategy- What to set.
-
setMetadataPolicyMergingStrategy
public void setMetadataPolicyMergingStrategy(@Nonnull BiFunction<Map<String, MetadataPolicy>, Map<String, MetadataPolicy>, Pair<Map<String, MetadataPolicy>, Boolean>> strategy) Set the strategy used for merging profile and token based metadata policies.- Parameters:
strategy- What to set.
-
setMetadataPolicyValidationStrategy
public void setMetadataPolicyValidationStrategy(@Nonnull Predicate<Map<String, MetadataPolicy>> strategy) Set the strategy used for validating token and merged metadata policies.- Parameters:
strategy- What to set.
-
doInitialize
- Overrides:
doInitializein classAbstractInitializableComponent- Throws:
ComponentInitializationException
-
doPreExecute
- Overrides:
doPreExecutein classAbstractConditionalProfileAction
-
doExecute
- Overrides:
doExecutein classAbstractProfileAction
-