Class InitializeAuthenticationContext

All Implemented Interfaces:
Component, DestructableComponent, InitializableComponent, ProfileAction, Aware, MessageSource, MessageSourceAware, Action

public class InitializeAuthenticationContext extends AbstractOIDCAuthenticationRequestAction
An action that creates an AuthenticationContext and attaches it to the current ProfileRequestContext.

As the incoming message is a OIDC AuthenticationRequest, the basic authentication policy (IsPassive, ForceAuthn) is interpreted from the request prompt parameter. If the incoming message has login_hint parameter the value of it is placed to hinted name.

  • Field Details

    • log

      @Nonnull private final org.slf4j.Logger log
      Class logger.
    • promptLookupStrategy

      @Nonnull private Function<ProfileRequestContext,com.nimbusds.openid.connect.sdk.Prompt> promptLookupStrategy
      Strategy used to obtain the requested prompt value.
    • loginHintLookupStrategy

      @Nonnull private Function<ProfileRequestContext,String> loginHintLookupStrategy
      Strategy used to obtain the request login hint value.
    • maxAgeLookupStrategy

      @Nonnull private Function<ProfileRequestContext,Duration> maxAgeLookupStrategy
      Strategy used to obtain the request max_age value.
    • forceAuthnPredicate

      @Nonnull private Predicate<ProfileRequestContext> forceAuthnPredicate
      Extracts forceAuthn property from profile config.
  • Constructor Details

    • InitializeAuthenticationContext

      public InitializeAuthenticationContext()
      Constructor.
  • Method Details

    • setPromptLookupStrategy

      public void setPromptLookupStrategy(@Nonnull Function<ProfileRequestContext,com.nimbusds.openid.connect.sdk.Prompt> strategy)
      Set the strategy used to locate the requested prompt.
      Parameters:
      strategy - lookup strategy
    • setLoginHintLookupStrategy

      public void setLoginHintLookupStrategy(@Nonnull Function<ProfileRequestContext,String> strategy)
      Set the strategy used to locate the request login hint.
      Parameters:
      strategy - lookup strategy
    • setMaxAgeLookupStrategy

      public void setMaxAgeLookupStrategy(@Nonnull Function<ProfileRequestContext,Duration> strategy)
      Set the strategy used to locate the request max age.
      Parameters:
      strategy - lookup strategy
    • setForceAuthnPredicate

      public void setForceAuthnPredicate(@Nonnull Predicate<ProfileRequestContext> condition)
      Set the predicate to apply to derive the message-independent forced authn default.
      Parameters:
      condition - condition to set
      Since:
      3.1.0
    • doExecute

      protected void doExecute(@Nonnull ProfileRequestContext profileRequestContext)
      Overrides:
      doExecute in class AbstractProfileAction