Package com.nimbusds.jose
Class JWECryptoParts
java.lang.Object
com.nimbusds.jose.JWECryptoParts
The cryptographic parts of a JSON Web Encryption (JWE) object.
- Version:
- 2024-04-20
- Author:
- Vladimir Dzhuvinov
-
Constructor Summary
ConstructorsConstructorDescriptionJWECryptoParts
(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authenticationTag) Creates a new cryptographic JWE parts instance.JWECryptoParts
(Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authenticationTag) Creates a new cryptographic JWE parts instance. -
Method Summary
Modifier and TypeMethodDescriptionGets the authentication tag.Gets the cipher text.Gets the encrypted key.Gets the modified JWE header.Gets the initialisation vector (IV).
-
Constructor Details
-
JWECryptoParts
public JWECryptoParts(Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authenticationTag) Creates a new cryptographic JWE parts instance.- Parameters:
encryptedKey
- The encrypted key,null
if not required by the encryption algorithm.iv
- The initialisation vector (IV),null
if not required by the encryption algorithm.cipherText
- The cipher text. Must not benull
.authenticationTag
- The authentication tag,null
if the JWE algorithm provides built-in integrity check.
-
JWECryptoParts
public JWECryptoParts(JWEHeader header, Base64URL encryptedKey, Base64URL iv, Base64URL cipherText, Base64URL authenticationTag) Creates a new cryptographic JWE parts instance.- Parameters:
header
- The modified JWE header,null
if not.encryptedKey
- The encrypted key,null
if not required by the encryption algorithm.iv
- The initialisation vector (IV),null
if not required by the encryption algorithm.cipherText
- The cipher text. Must not benull
.authenticationTag
- The authentication tag,null
if the JWE algorithm provides built-in integrity check.
-
-
Method Details
-
getHeader
Gets the modified JWE header.- Returns:
- The modified JWE header,
null
of not.
-
getEncryptedKey
Gets the encrypted key.- Returns:
- The encrypted key,
null
if not required by the JWE algorithm orrecipients
are specified.
-
getInitializationVector
Gets the initialisation vector (IV).- Returns:
- The initialisation vector (IV),
null
if not required by the JWE algorithm.
-
getCipherText
Gets the cipher text.- Returns:
- The cipher text.
-
getAuthenticationTag
Gets the authentication tag.- Returns:
- The authentication tag,
null
if the encryption algorithm provides built-in integrity checking.
-