Package com.nimbusds.jose
Class JWECryptoParts
- java.lang.Object
-
- com.nimbusds.jose.JWECryptoParts
-
@Immutable public final class JWECryptoParts extends Object
The cryptographic parts of a JSON Web Encryption (JWE) object.- Version:
- 2021-09-30
- Author:
- Vladimir Dzhuvinov
-
-
Constructor Summary
Constructors Constructor Description JWECryptoParts(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
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Base64URL
getAuthenticationTag()
Gets the authentication tag.Base64URL
getCipherText()
Gets the cipher text.Base64URL
getEncryptedKey()
Gets the encrypted key.JWEHeader
getHeader()
Gets the modified JWE header.Base64URL
getInitializationVector()
Gets the initialisation vector (IV).
-
-
-
Constructor Detail
-
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 Detail
-
getHeader
public JWEHeader getHeader()
Gets the modified JWE header.- Returns:
- The modified JWE header,
null
of not.
-
getEncryptedKey
public Base64URL getEncryptedKey()
Gets the encrypted key.- Returns:
- The encrypted key,
null
if not required by the JWE algorithm orrecipients
are specified.
-
getInitializationVector
public Base64URL getInitializationVector()
Gets the initialisation vector (IV).- Returns:
- The initialisation vector (IV),
null
if not required by the JWE algorithm.
-
getCipherText
public Base64URL getCipherText()
Gets the cipher text.- Returns:
- The cipher text.
-
getAuthenticationTag
public Base64URL getAuthenticationTag()
Gets the authentication tag.- Returns:
- The authentication tag,
null
if the encryption algorithm provides built-in integrity checking.
-
-