@ThreadSafe public class DefaultJWEDecrypterFactory extends Object implements JWEDecrypterFactory
Supports all standard JWE algorithms implemented in the
com.nimbusds.jose.crypto
package.
Modifier and Type | Field and Description |
---|---|
static Set<JWEAlgorithm> |
SUPPORTED_ALGORITHMS
The supported JWE algorithms.
|
static Set<EncryptionMethod> |
SUPPORTED_ENCRYPTION_METHODS
The supported encryption methods.
|
Constructor and Description |
---|
DefaultJWEDecrypterFactory() |
Modifier and Type | Method and Description |
---|---|
JWEDecrypter |
createJWEDecrypter(JWEHeader header,
Key key)
Creates a new JWE decrypter for the specified header and key.
|
JWEJCAContext |
getJCAContext()
Returns the Java Cryptography Architecture (JCA) context.
|
Set<EncryptionMethod> |
supportedEncryptionMethods()
Returns the names of the supported encryption methods by the JWE
provier.
|
Set<JWEAlgorithm> |
supportedJWEAlgorithms()
Returns the names of the supported algorithms by the JWE provider
instance.
|
public static final Set<JWEAlgorithm> SUPPORTED_ALGORITHMS
public static final Set<EncryptionMethod> SUPPORTED_ENCRYPTION_METHODS
public DefaultJWEDecrypterFactory()
public Set<JWEAlgorithm> supportedJWEAlgorithms()
JWEProvider
alg
JWE header parameter.supportedJWEAlgorithms
in interface JWEProvider
public Set<EncryptionMethod> supportedEncryptionMethods()
JWEProvider
enc
JWE header parameter.supportedEncryptionMethods
in interface JWEProvider
public JWEJCAContext getJCAContext()
JCAAware
getJCAContext
in interface JCAAware<JWEJCAContext>
null
.public JWEDecrypter createJWEDecrypter(JWEHeader header, Key key) throws JOSEException
JWEDecrypterFactory
createJWEDecrypter
in interface JWEDecrypterFactory
header
- The JWE header. Not null
.key
- The key intended to verify the JWS message. Not
null
.JOSEException
- If the JWE algorithm / encryption method is
not supported or the key type or length
doesn't match expected for the JWE algorithm.Copyright © 2017 Connect2id Ltd.. All rights reserved.