Class PrivateKeyJwtClientAuthenticationFilter.Builder<T extends PrivateKeyJwtClientAuthenticationFilter.Builder<T>>

    • Constructor Detail

      • Builder

        public Builder()
    • Method Detail

      • self

        protected T self()
        Returns this object, as its actual type.
        Returns:
        this object.
      • withClientId

        public T withClientId​(String clientId)
        Sets the client id that will be used in the private key jwt.
        Parameters:
        clientId - The client id that will be used in the private key jwt.
        Returns:
        The builder.
      • withTokenEndpoint

        public T withTokenEndpoint​(URI tokenEndpoint)
        Sets the token end point used to specify as the aud in the private key jwt.
        Parameters:
        tokenEndpoint - The token end point used to specify as the aud in the private key jwt.
        Returns:
        The builder.
      • withSecretsProvider

        @Deprecated(since="26.2.0",
                    forRemoval=true)
        public T withSecretsProvider​(SecretsProvider secretsProvider)
        Deprecated, for removal: This API element is subject to removal in a future version.
        Please use SecretReference API instead. Will be removed in winter 2021 season.
        Sets the secrets provider to use to resolve keys where a Purpose is used.
        Parameters:
        secretsProvider - The secrets provider.
        Returns:
        The builder.
      • withSigningSecretReference

        public T withSigningSecretReference​(SecretReference<SigningKey> secretReference)
        Sets SecretReference to use as the signing key. Note that this is the preferred way of providing the signing secret reference, though you may alternatively provide both the signing Purpose and SecretsProvider.
        Parameters:
        secretReference - The secret reference used to sign the JWT.
        Returns:
        The builder.
      • withSigningAlgorithm

        public T withSigningAlgorithm​(JwsAlgorithm signingAlgorithm)
        Sets algorithm used to sign the private key jwt.
        Parameters:
        signingAlgorithm - The algorithm used to sign the private key jwt.
        Returns:
        The builder.
      • withPrivateKeyJwtExpiryTime

        public T withPrivateKeyJwtExpiryTime​(Duration privateKeyJwtExpiryTime)
        Sets duration after the jwt will expire.
        Parameters:
        privateKeyJwtExpiryTime - The duration after the jwt will expire.
        Returns:
        The builder.
      • withClock

        public T withClock​(Clock clock)
        Sets the clock instance.
        Parameters:
        clock - The clock instance.
        Returns:
        The builder.
      • withClaims

        public T withClaims​(Map<String,​Object> claims)
        Sets any additional JWT claims, which may be overridden by claims created as part of creation of the private-key JWT.
        Parameters:
        claims - Any additional JWT claims.
        Returns:
        The builder.
      • buildSecretReferences

        @Deprecated(since="26.2.0",
                    forRemoval=true)
        protected void buildSecretReferences()
        Deprecated, for removal: This API element is subject to removal in a future version.
        for removal with withSigningPurpose(Purpose). Will be removed in winter 2021 season.
        Set the signing secret reference in the builder based on supplied configuration, whether by direct provision of the SecretReference or via the SecretsProvider and Purpose. This method provides compatibility between these two ways of providing the signing secret reference.