Class ValidateConfiguration

All Implemented Interfaces:
ConditionalProfileConfiguration, ProfileConfiguration, Component, DestructableComponent, IdentifiableComponent, IdentifiedComponent, InitializableComponent

public class ValidateConfiguration
extends AbstractProtocolConfiguration
CAS protocol configuration. Applies to the following ticket validation URIs:
  • /proxyValidate
  • /serviceValidate
  • Field Details

  • Constructor Details

    • ValidateConfiguration

      public ValidateConfiguration()
      Creates a new instance.
  • Method Details

    • getPGTIOUGenerator

      @Nonnull public IdentifierGenerationStrategy getPGTIOUGenerator​(@Nullable ProfileRequestContext profileRequestContext)
      Get the PGTIOU ticket ID generator.
      Parameters:
      profileRequestContext - current profile request context
      Returns:
      PGTIOU ticket ID generator
    • setPGTIOUGenerator

      public void setPGTIOUGenerator​(@Nonnull IdentifierGenerationStrategy generator)
      Set the PGTIOU ticket ID generator.
      Parameters:
      generator - ID generator
    • setPGTIOUGeneratorLookupStrategy

      public void setPGTIOUGeneratorLookupStrategy​(@Nonnull Function<ProfileRequestContext,​IdentifierGenerationStrategy> strategy)
      Set the lookup strategy to use for the PGTIOU ticket ID generator.
      Parameters:
      strategy - lookup strategy
      Since:
      3.3.0
    • getServiceComparator

      @Nonnull public Comparator<String> getServiceComparator​(@Nullable ProfileRequestContext profileRequestContext)
      Get component responsible for enforcing ticket requester matches ticket validator.
      Parameters:
      profileRequestContext - current profile request context
      Returns:
      ticket requester/validator comparator
    • setServiceComparator

      public void setServiceComparator​(@Nonnull Comparator<String> comparator)
      Set component responsible for enforcing ticket requester matches ticket validator.
      Parameters:
      comparator - ticket requester/validator comparator
    • setServiceComparatorLookupStrategy

      public void setServiceComparatorLookupStrategy​(@Nonnull Function<ProfileRequestContext,​Comparator<String>> strategy)
      Set the lookup strategy to use for the component responsible for enforcing that the ticket requester matches the ticket validator.
      Parameters:
      strategy - lookup strategy
      Since:
      3.3.0
    • getUserAttribute

      @Nullable public String getUserAttribute​(@Nullable ProfileRequestContext profileRequestContext)
      Get name of IdP attribute to use for username returned in CAS ticket validation response.
      Parameters:
      profileRequestContext - current profile request context
      Returns:
      attribute name
    • setUserAttribute

      public void setUserAttribute​(@Nullable String attribute)
      Set the name of IdP attribute to use for username returned in CAS ticket validation response.
      Parameters:
      attribute - attribute name to use
    • setUserAttributeLookupStrategy

      public void setUserAttributeLookupStrategy​(@Nonnull Function<ProfileRequestContext,​String> strategy)
      Set the lookup strategy to use for the name of the IdP attribute to use for username returned in CAS ticket validation response.
      Parameters:
      strategy - lookup strategy
      Since:
      3.3.0
    • getDefaultTicketPrefix

      @Nonnull @NotEmpty protected String getDefaultTicketPrefix()
      Get default ticket prefix.
      Specified by:
      getDefaultTicketPrefix in class AbstractProtocolConfiguration
      Returns:
      prefix
    • getDefaultTicketLength

      protected int getDefaultTicketLength()
      Get default ticket length.
      Specified by:
      getDefaultTicketLength in class AbstractProtocolConfiguration
      Returns:
      length