public class SecretEncryption extends AbstractEncryptionConfiguration
algorithm, method
Constructor and Description |
---|
SecretEncryption(SecretEncryptionConfiguration secretEncryptionConfiguration) |
Modifier and Type | Method and Description |
---|---|
protected com.nimbusds.jose.JWEDecrypter |
buildDecrypter()
Build the appropriate decrypter.
|
protected com.nimbusds.jose.JWEEncrypter |
buildEncrypter()
Build the appropriate encrypter.
|
String |
getSecret() |
void |
setSecret(String secret)
Sets secret byte[] with a string with UTF_8 charset.
|
String |
supportedAlgorithmsMessage() |
boolean |
supports(com.nimbusds.jose.JWEAlgorithm algorithm,
com.nimbusds.jose.EncryptionMethod method)
Whether this encryption configuration supports this algorithm and encryption method.
|
decrypt, encrypt, getAlgorithm, getMethod, setAlgorithm, setMethod
public SecretEncryption(SecretEncryptionConfiguration secretEncryptionConfiguration)
secretEncryptionConfiguration
- Instance of SecretEncryptionConfiguration
public boolean supports(com.nimbusds.jose.JWEAlgorithm algorithm, com.nimbusds.jose.EncryptionMethod method)
EncryptionConfiguration
algorithm
- the encryption algorithmmethod
- the encryption methodpublic String supportedAlgorithmsMessage()
protected com.nimbusds.jose.JWEEncrypter buildEncrypter() throws com.nimbusds.jose.KeyLengthException
AbstractEncryptionConfiguration
buildEncrypter
in class AbstractEncryptionConfiguration
com.nimbusds.jose.KeyLengthException
protected com.nimbusds.jose.JWEDecrypter buildDecrypter() throws com.nimbusds.jose.KeyLengthException
AbstractEncryptionConfiguration
buildDecrypter
in class AbstractEncryptionConfiguration
com.nimbusds.jose.KeyLengthException
public String getSecret()
public void setSecret(String secret)
secret
- UTF_8 string