Package org.forgerock.http.oauth2
Class EncryptedPrivateKeyJwtClientAuthenticationFilter.Builder
java.lang.Object
org.forgerock.http.oauth2.PrivateKeyJwtClientAuthenticationFilter.Builder<EncryptedPrivateKeyJwtClientAuthenticationFilter.Builder>
org.forgerock.http.oauth2.EncryptedPrivateKeyJwtClientAuthenticationFilter.Builder
- Enclosing class:
- EncryptedPrivateKeyJwtClientAuthenticationFilter
public static class EncryptedPrivateKeyJwtClientAuthenticationFilter.Builder
extends PrivateKeyJwtClientAuthenticationFilter.Builder<EncryptedPrivateKeyJwtClientAuthenticationFilter.Builder>
Builder class for creating the Encrypted PrivateKey Jwt ClientAuthentication Filter.
-
Field Summary
Fields inherited from class org.forgerock.http.oauth2.PrivateKeyJwtClientAuthenticationFilter.Builder
secretsProvider -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the EncryptedPrivateKeyAuthFilter instance.protected voidDeprecated, for removal: This API element is subject to removal in a future version.toString()withEncryptionAlgorithm(JweAlgorithm encryptionAlgorithm) Sets algorithm used to encrypt the private key jwt.withEncryptionMethod(EncryptionMethod encryptionMethod) Sets encryption method used to encrypt the private key jwt.withEncryptionPurpose(Purpose<DataEncryptionKey> encryptionPurpose) Deprecated, for removal: This API element is subject to removal in a future version.Please usewithEncryptionSecretReference(SecretReference)instead.withEncryptionSecretReference(SecretReference<DataEncryptionKey> secretReference) SetsSecretReferenceto use as the encryption key.Methods inherited from class org.forgerock.http.oauth2.PrivateKeyJwtClientAuthenticationFilter.Builder
self, withClaims, withClientId, withClock, withPrivateKeyJwtExpiryTime, withSecretsProvider, withSigningAlgorithm, withSigningPurpose, withSigningSecretReference, withTokenEndpoint
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
withEncryptionPurpose
@Deprecated(since="26.2.0", forRemoval=true) public EncryptedPrivateKeyJwtClientAuthenticationFilter.Builder withEncryptionPurpose(Purpose<DataEncryptionKey> encryptionPurpose) Deprecated, for removal: This API element is subject to removal in a future version.Please usewithEncryptionSecretReference(SecretReference)instead. Will be removed in winter 2021 season.Sets purpose to look up the encryption key. Note that you should provide either theSecretReference(preferred) or both the encryptionPurposeandSecretsProvider, so that the encryption key can be determined.- Parameters:
encryptionPurpose- The purpose to look up the encryption key to encrypt the private key jwt.- Returns:
- The builder.
-
withEncryptionSecretReference
public EncryptedPrivateKeyJwtClientAuthenticationFilter.Builder withEncryptionSecretReference(SecretReference<DataEncryptionKey> secretReference) SetsSecretReferenceto use as the encryption key. Note that this is the preferred way of providing the encryption secret reference, though you may alternatively provide both the encryptionPurposeandSecretsProvider.- Parameters:
secretReference- The secret reference used to encrypt the JWT.- Returns:
- The builder.
-
withEncryptionAlgorithm
public EncryptedPrivateKeyJwtClientAuthenticationFilter.Builder withEncryptionAlgorithm(JweAlgorithm encryptionAlgorithm) Sets algorithm used to encrypt the private key jwt.- Parameters:
encryptionAlgorithm- The algorithm used to encrypt the private key jwt.- Returns:
- The builder.
-
withEncryptionMethod
public EncryptedPrivateKeyJwtClientAuthenticationFilter.Builder withEncryptionMethod(EncryptionMethod encryptionMethod) Sets encryption method used to encrypt the private key jwt.- Parameters:
encryptionMethod- The encryption method used to encrypt the private key jwt.- Returns:
- The builder.
-
build
Builds the EncryptedPrivateKeyAuthFilter instance.- Overrides:
buildin classPrivateKeyJwtClientAuthenticationFilter.Builder<EncryptedPrivateKeyJwtClientAuthenticationFilter.Builder>- Returns:
- The EncryptedPrivateKeyAuthFilter.
-
buildSecretReferences
Deprecated, for removal: This API element is subject to removal in a future version.for removal withwithEncryptionPurpose(Purpose). Will be removed in winter 2021 season.Set the signing and encryption secret references in the builder based on supplied configuration, whether by direct provision of theSecretReferenceor via theSecretsProviderandPurpose, for signing and encryption respectively. This method provides compatibility between these two ways of providing the signing and encryption secret references. -
toString
-
withEncryptionPurpose(Purpose).