public interface JWEDecrypter extends JWEAlgorithmProvider
Callers can query the decrypter to determine its algorithm capabilities as well as the JWE algorithms and header parameters that are accepted for processing.
| Modifier and Type | Method and Description |
|---|---|
byte[] |
decrypt(ReadOnlyJWEHeader header,
Base64URL encryptedKey,
Base64URL iv,
Base64URL cipherText,
Base64URL integrityValue)
Decrypts the specified cipher text of a
JWE Object. |
JWEHeaderFilter |
getJWEHeaderFilter()
Gets the JWE header filter associated with the decrypter.
|
supportedAlgorithms, supportedEncryptionMethodsJWEHeaderFilter getJWEHeaderFilter()
supported JWE
algorithms and header parameters that the decrypter is configured to
accept.
Attempting to decrypt a JWE object with an
algorithm or header parameter that is not accepted must result in a
JOSEException.
byte[] decrypt(ReadOnlyJWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL integrityValue) throws JOSEException
JWE Object.header - The JSON Web Encryption (JWE) header. Must
specify an accepted JWE algorithm, must contain
only accepted header parameters, and must not
be null.encryptedKey - The encrypted key, null if not required
by the JWE algorithm.iv - The initialisation vector, null if not
required by the JWE algorithm.cipherText - The cipher text to decrypt. Must not be
null.integrityValue - The integrity value, null if not
required by the JWE algorithm.JOSEException - If the JWE algorithm is not accepted, if a
header parameter is not accepted, or if
decryption failed for some other reason.Copyright © 2013 NimbusDS. All Rights Reserved.