Class ValidateCodeChallenge

    • Field Detail

      • log

        @Nonnull
        private org.slf4j.Logger log
        Class logger.
      • allowPKCEPlainCondition

        @Nonnull
        private Predicate<ProfileRequestContext> allowPKCEPlainCondition
        Strategy used to determine whether to allow plaintext PKCE.
      • codeChallengeMethodLookupStrategy

        @Nonnull
        private Function<ProfileRequestContext,​String> codeChallengeMethodLookupStrategy
        Strategy used to locate the code challenge method.
      • forcePKCE

        private boolean forcePKCE
        Whether PKCE is mandatory.
      • plainPKCE

        private boolean plainPKCE
        Whether plain PKCE is allowed.
      • codeChallenge

        @Nullable
        private String codeChallenge
        PKCE code challenge.
      • codeChallengeMethod

        @Nullable
        private String codeChallengeMethod
        PKCE code challenge method.
    • Constructor Detail

      • ValidateCodeChallenge

        public ValidateCodeChallenge()
        Constructor.
    • Method Detail

      • setForcePKCECondition

        public void setForcePKCECondition​(@Nonnull
                                          Predicate<ProfileRequestContext> condition)
        Set the condition used to determine whether to require PKCE.
        Parameters:
        condition - condition to apply
      • setAllowPKCEPlainCondition

        public void setAllowPKCEPlainCondition​(@Nonnull
                                               Predicate<ProfileRequestContext> condition)
        Set the condition used to determine whether to allow plaintext PKCE.
        Parameters:
        condition - condition to apply
      • setCodeChallengeLookupStrategy

        public void setCodeChallengeLookupStrategy​(@Nonnull
                                                   Function<ProfileRequestContext,​String> strategy)
        Set the strategy used to locate the Code Challenge of the request.
        Parameters:
        strategy - lookup strategy
      • setCodeChallengeMethodLookupStrategy

        public void setCodeChallengeMethodLookupStrategy​(@Nonnull
                                                         Function<ProfileRequestContext,​String> strategy)
        Set the strategy used to locate the Code Challenge Method of the request.
        Parameters:
        strategy - lookup strategy