Class DefaultNameIdentifierFormatStrategy
- java.lang.Object
-
- org.opensaml.saml.common.profile.logic.MetadataNameIdentifierFormatStrategy
-
- net.shibboleth.idp.saml.profile.logic.DefaultNameIdentifierFormatStrategy
-
- All Implemented Interfaces:
Function<ProfileRequestContext,List<String>>
public class DefaultNameIdentifierFormatStrategy extends MetadataNameIdentifierFormatStrategy
Function to filter a set of candidate NameIdentifier/NameID Format values derived from an entity's SAML metadata against configuration preferences.
-
-
Field Summary
Fields Modifier and Type Field Description private StringdefaultFormatDefault format to use if nothing else is known.private org.slf4j.LoggerlogClass logger.private StringprofileIdOverride theProfileConfigurationto look for rather than whatever's populated.private Function<ProfileRequestContext,RelyingPartyContext>relyingPartyContextLookupStrategyStrategy used to locate theRelyingPartyContextassociated with a givenProfileRequestContext.
-
Constructor Summary
Constructors Constructor Description DefaultNameIdentifierFormatStrategy()Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description List<String>apply(ProfileRequestContext input)voidsetDefaultFormat(String format)Set the default format to return.voidsetProfileId(String id)Set the profile configuration ID to locate in theRelyingPartyConfigurationfor the purposes of establishing format precedence rules.voidsetRelyingPartyContextLookupStrategy(Function<ProfileRequestContext,RelyingPartyContext> strategy)Set the strategy used to locate theRelyingPartyContextassociated with a givenProfileRequestContext.-
Methods inherited from class org.opensaml.saml.common.profile.logic.MetadataNameIdentifierFormatStrategy
setSSODescriptorLookupStrategy
-
-
-
-
Field Detail
-
log
@Nonnull private final org.slf4j.Logger log
Class logger.
-
relyingPartyContextLookupStrategy
@Nonnull private Function<ProfileRequestContext,RelyingPartyContext> relyingPartyContextLookupStrategy
Strategy used to locate theRelyingPartyContextassociated with a givenProfileRequestContext.
-
profileId
@Nullable private String profileId
Override theProfileConfigurationto look for rather than whatever's populated.
-
-
Method Detail
-
setRelyingPartyContextLookupStrategy
public void setRelyingPartyContextLookupStrategy(@Nonnull Function<ProfileRequestContext,RelyingPartyContext> strategy)Set the strategy used to locate theRelyingPartyContextassociated with a givenProfileRequestContext.- Parameters:
strategy- strategy used to locate theRelyingPartyContextassociated with a givenProfileRequestContext
-
setProfileId
public void setProfileId(@Nullable String id)Set the profile configuration ID to locate in theRelyingPartyConfigurationfor the purposes of establishing format precedence rules.By default/without one set, the strategy is to use the configuration object populated in the
RelyingPartyContext.- Parameters:
id- profile ID to look for
-
setDefaultFormat
public void setDefaultFormat(@Nonnull @NotEmpty String format)
Set the default format to return.- Parameters:
format- default format
-
apply
@Nullable public List<String> apply(@Nullable ProfileRequestContext input)
- Specified by:
applyin interfaceFunction<ProfileRequestContext,List<String>>- Overrides:
applyin classMetadataNameIdentifierFormatStrategy
-
-