@ThreadSafe public class DefaultJWEHeaderFilter extends DefaultHeaderFilter implements JWEHeaderFilter
JWEDecrypter implementations. This class is
thread-safe.| Constructor and Description |
|---|
DefaultJWEHeaderFilter(Set<JWEAlgorithm> algs,
Set<EncryptionMethod> encs)
Creates a new JWE header filter.
|
DefaultJWEHeaderFilter(Set<JWEAlgorithm> algs,
Set<EncryptionMethod> encs,
Set<String> acceptedParams)
Creates a new JWE header filter.
|
| Modifier and Type | Method and Description |
|---|---|
Set<JWEAlgorithm> |
getAcceptedAlgorithms()
Gets the names of the accepted JWE algorithms.
|
Set<EncryptionMethod> |
getAcceptedEncryptionMethods()
Gets the names of the accepted encryption methods.
|
void |
setAcceptedAlgorithms(Set<JWEAlgorithm> acceptedAlgs)
Sets the names of the accepted JWE algorithms.
|
void |
setAcceptedEncryptionMethods(Set<EncryptionMethod> acceptedEncs)
Sets the names of the accepted encryption methods.
|
void |
setAcceptedParameters(Set<String> acceptedParams)
Sets the names of the accepted header parameters.
|
Set<JWEAlgorithm> |
supportedAlgorithms()
Returns the names of the supported JWE algorithms.
|
Set<EncryptionMethod> |
supportedEncryptionMethods()
Returns the names of the supported encryption methods.
|
getAcceptedParametersclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetAcceptedParameterspublic DefaultJWEHeaderFilter(Set<JWEAlgorithm> algs, Set<EncryptionMethod> encs)
JWEHeader.getRegisteredParameterNames().algs - The supported JWE algorithms. Used to bound the
accepted algorithms. Must
not be null.encs - The supported encryption methods. Used to bound the
accepted encryption
methods. Must not be null.public DefaultJWEHeaderFilter(Set<JWEAlgorithm> algs, Set<EncryptionMethod> encs, Set<String> acceptedParams)
algs - The supported JWE algorithms. Used to bound
the accepted
algorithms. Must not be null.encs - The supported encryption methods. Used to
bound the accepted encryption methods. Must not be
null.acceptedParams - The accepted JWE header parameters. Must
contain at least the alg and
enc parameters. Must not be
null.public Set<JWEAlgorithm> supportedAlgorithms()
accepted algorithms.public Set<JWEAlgorithm> getAcceptedAlgorithms()
JWEHeaderFilteralg JWE header parameter.getAcceptedAlgorithms in interface JWEHeaderFilterpublic void setAcceptedAlgorithms(Set<JWEAlgorithm> acceptedAlgs)
JWEHeaderFilteralg JWE header parameter.setAcceptedAlgorithms in interface JWEHeaderFilteracceptedAlgs - The accepted JWE algorithms. Must be a subset of
the supported algorithms and not null.public Set<EncryptionMethod> supportedEncryptionMethods()
accepted encryption
methods.public Set<EncryptionMethod> getAcceptedEncryptionMethods()
JWEHeaderFilterenc JWE header parameter.getAcceptedEncryptionMethods in interface JWEHeaderFilterpublic void setAcceptedEncryptionMethods(Set<EncryptionMethod> acceptedEncs)
JWEHeaderFilterenc JWE header parameter.setAcceptedEncryptionMethods in interface JWEHeaderFilteracceptedEncs - The accepted encryption methods. Must be a
subset of the supported encryption methods and
not null.public void setAcceptedParameters(Set<String> acceptedParams)
HeaderFiltersetAcceptedParameters in interface HeaderFiltersetAcceptedParameters in class DefaultHeaderFilteracceptedParams - The accepted header parameters. Must contain
at least the alg parameter for JWS
headers or the alg and enc
parameters for JWE headers. Must not be
null.Copyright © 2013 NimbusDS. All Rights Reserved.