Class JweDecryptionConstraint
- java.lang.Object
-
- org.forgerock.openig.tools.jwt.validation.JweDecryptionConstraint
-
- All Implemented Interfaces:
JwtConstraint
public class JweDecryptionConstraint extends Object implements JwtConstraint
Class supportingEncryptedJwt
encryption verification with a verificationPurpose
and aSecretsProvider
responsible for getting the decryption key.
-
-
Constructor Summary
Constructors Constructor Description JweDecryptionConstraint(SecretsProvider secretsProvider, Purpose<DataDecryptionKey> purpose)
Construct aJweDecryptionConstraint
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Promise<Result,NeverThrowsException>
apply(ValidatorConstraintContext constraintContext)
Apply a constraint to the given JWT.
-
-
-
Constructor Detail
-
JweDecryptionConstraint
public JweDecryptionConstraint(SecretsProvider secretsProvider, Purpose<DataDecryptionKey> purpose)
Construct aJweDecryptionConstraint
.- Parameters:
secretsProvider
- the instance from where to get the keys.purpose
- thePurpose
of the decryption.
-
-
Method Detail
-
apply
public Promise<Result,NeverThrowsException> apply(ValidatorConstraintContext constraintContext)
Description copied from interface:JwtConstraint
Apply a constraint to the given JWT.- Specified by:
apply
in interfaceJwtConstraint
- Parameters:
constraintContext
- The validation context used to hold data between constraints validation- Returns:
- a
Result
promise for thisJwtConstraint
.
-
-