Package net.shibboleth.idp.cas.config
Class AbstractProtocolConfiguration
- java.lang.Object
-
- net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
-
- net.shibboleth.utilities.java.support.component.AbstractIdentifiedInitializableComponent
-
- net.shibboleth.utilities.java.support.component.AbstractIdentifiableInitializableComponent
-
- net.shibboleth.idp.profile.config.AbstractProfileConfiguration
-
- net.shibboleth.idp.profile.config.AbstractConditionalProfileConfiguration
-
- net.shibboleth.idp.cas.config.AbstractProtocolConfiguration
-
- All Implemented Interfaces:
net.shibboleth.idp.profile.config.ConditionalProfileConfiguration,net.shibboleth.idp.profile.config.ProfileConfiguration,net.shibboleth.utilities.java.support.component.Component,net.shibboleth.utilities.java.support.component.DestructableComponent,net.shibboleth.utilities.java.support.component.IdentifiableComponent,net.shibboleth.utilities.java.support.component.IdentifiedComponent,net.shibboleth.utilities.java.support.component.InitializableComponent
- Direct Known Subclasses:
LoginConfiguration,ProxyConfiguration,ValidateConfiguration
public abstract class AbstractProtocolConfiguration extends net.shibboleth.idp.profile.config.AbstractConditionalProfileConfiguration implements net.shibboleth.utilities.java.support.component.InitializableComponentBase class for CAS protocol configuration.
-
-
Field Summary
Fields Modifier and Type Field Description static DurationDEFAULT_TICKET_VALIDITY_PERIODDefault ticket validity.private net.shibboleth.idp.profile.config.SecurityConfigurationdefaultSecurityConfigurationHolds default security config object to use.static StringPROTOCOL_URICAS base protocol URI.private Predicate<org.opensaml.profile.context.ProfileRequestContext>resolveAttributesPredicateWhether attributes should be resolved in the course of the profile.private Function<org.opensaml.profile.context.ProfileRequestContext,Duration>ticketValidityPeriodLookupStrategyLookup function to supply ticketValidityPeriod property.
-
Constructor Summary
Constructors Constructor Description AbstractProtocolConfiguration(String profileId)Creates a new configuration instance.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract intgetDefaultTicketLength()Get default ticket length.protected abstract StringgetDefaultTicketPrefix()Get default ticket prefix.net.shibboleth.idp.profile.config.SecurityConfigurationgetSecurityConfiguration(org.opensaml.profile.context.ProfileRequestContext profileRequestContext)DurationgetTicketValidityPeriod(org.opensaml.profile.context.ProfileRequestContext profileRequestContext)Get ticket validity period.booleanisResolveAttributes(org.opensaml.profile.context.ProfileRequestContext profileRequestContext)Get whether attributes should be resolved during the profile (defaults to true).voidsetResolveAttributes(boolean flag)Set whether attributes should be resolved during the profile.voidsetResolveAttributesPredicate(Predicate<org.opensaml.profile.context.ProfileRequestContext> condition)Set a condition to determine whether attributes should be resolved during the profile.voidsetTicketValidityPeriod(Duration ticketTTL)Sets the ticket validity period.voidsetTicketValidityPeriodLookupStrategy(Function<org.opensaml.profile.context.ProfileRequestContext,Duration> strategy)Set a lookup strategy for the ticket validity period.-
Methods inherited from class net.shibboleth.idp.profile.config.AbstractConditionalProfileConfiguration
getActivationCondition, setActivationCondition
-
Methods inherited from class net.shibboleth.idp.profile.config.AbstractProfileConfiguration
equals, getDisallowedFeatures, getInboundInterceptorFlows, getOutboundInterceptorFlows, hashCode, isFeatureDisallowed, setDisallowedFeatures, setDisallowedFeaturesLookupStrategy, setInboundFlowsLookupStrategy, setInboundInterceptorFlows, setOutboundFlowsLookupStrategy, setOutboundInterceptorFlows, setSecurityConfiguration, setSecurityConfigurationLookupStrategy
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractIdentifiableInitializableComponent
setId
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractIdentifiedInitializableComponent
doInitialize, getId
-
Methods inherited from class net.shibboleth.utilities.java.support.component.AbstractInitializableComponent
destroy, doDestroy, initialize, isDestroyed, isInitialized
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface net.shibboleth.utilities.java.support.component.IdentifiedComponent
getId
-
-
-
-
Field Detail
-
PROTOCOL_URI
@Nonnull @NotEmpty public static final String PROTOCOL_URI
CAS base protocol URI.- See Also:
- Constant Field Values
-
DEFAULT_TICKET_VALIDITY_PERIOD
@Nonnull public static final Duration DEFAULT_TICKET_VALIDITY_PERIOD
Default ticket validity.
-
ticketValidityPeriodLookupStrategy
@Nonnull private Function<org.opensaml.profile.context.ProfileRequestContext,Duration> ticketValidityPeriodLookupStrategy
Lookup function to supply ticketValidityPeriod property.
-
resolveAttributesPredicate
@Nonnull private Predicate<org.opensaml.profile.context.ProfileRequestContext> resolveAttributesPredicate
Whether attributes should be resolved in the course of the profile.
-
defaultSecurityConfiguration
@Nonnull private final net.shibboleth.idp.profile.config.SecurityConfiguration defaultSecurityConfiguration
Holds default security config object to use.
-
-
Constructor Detail
-
AbstractProtocolConfiguration
public AbstractProtocolConfiguration(@Nonnull @NotEmpty String profileId)Creates a new configuration instance.- Parameters:
profileId- Unique profile identifier
-
-
Method Detail
-
getSecurityConfiguration
@Nullable public net.shibboleth.idp.profile.config.SecurityConfiguration getSecurityConfiguration(@Nullable org.opensaml.profile.context.ProfileRequestContext profileRequestContext)- Specified by:
getSecurityConfigurationin interfacenet.shibboleth.idp.profile.config.ProfileConfiguration- Overrides:
getSecurityConfigurationin classnet.shibboleth.idp.profile.config.AbstractProfileConfiguration
-
getTicketValidityPeriod
@Nonnull public Duration getTicketValidityPeriod(@Nullable org.opensaml.profile.context.ProfileRequestContext profileRequestContext)
Get ticket validity period.- Parameters:
profileRequestContext- current profile request context- Returns:
- ticket validity period
-
setTicketValidityPeriod
public void setTicketValidityPeriod(@Nonnull Duration ticketTTL)Sets the ticket validity period.- Parameters:
ticketTTL- ticket validity period
-
setTicketValidityPeriodLookupStrategy
public void setTicketValidityPeriodLookupStrategy(@Nonnull Function<org.opensaml.profile.context.ProfileRequestContext,Duration> strategy)Set a lookup strategy for the ticket validity period.- Parameters:
strategy- lookup strategy- Since:
- 3.3.0
-
isResolveAttributes
public boolean isResolveAttributes(@Nullable org.opensaml.profile.context.ProfileRequestContext profileRequestContext)Get whether attributes should be resolved during the profile (defaults to true).- Parameters:
profileRequestContext- current profile request context- Returns:
- true iff attributes should be resolved
-
setResolveAttributes
public void setResolveAttributes(boolean flag)
Set whether attributes should be resolved during the profile.- Parameters:
flag- flag to set
-
setResolveAttributesPredicate
public void setResolveAttributesPredicate(@Nonnull Predicate<org.opensaml.profile.context.ProfileRequestContext> condition)Set a condition to determine whether attributes should be resolved during the profile.- Parameters:
condition- condition to set- Since:
- 3.3.0
-
getDefaultTicketPrefix
@Nonnull @NotEmpty protected abstract String getDefaultTicketPrefix()
Get default ticket prefix.- Returns:
- prefix
-
getDefaultTicketLength
protected abstract int getDefaultTicketLength()
Get default ticket length.- Returns:
- length
-
-