- All Implemented Interfaces:
Serializable
,Comparable<WebCryptoHeader.Param>
,Constable
- Enclosing interface:
WebCryptoHeader
Enumerates standard header parameters.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionEncryption/signature algorithm.Certificate chain.Certificate SHA-1 thumb print.Certificate SHA-1 thumb print.Certificate chain URI.Content media type.Extended parameter names that must be included in the protected header.Content encryption algorithm.Ephemeral public key for key agreement algorithms.Initialization vector for GCM key wrap.Well-known public key.Well-known key identifier.Well-known key set URI.Public originator identifier (PartyUInfo) for key derivation.Public recipient identifier (PartyVInfo) for key derivation.PBKDF2 iteration count for use with PBES2.Password salt for use with PBES2.Authentication tag for GCM key wrap.Signature/encryption media type.Plain-text compression algorithm for encryption. -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic WebCryptoHeader.Param
Gets a parameter by JOSE standard parameter name.get
(WebCryptoHeader header) Gets the header value.boolean
isPresent
(WebCryptoHeader header) Verifies that the header contains a non-null value.boolean
isUsedFor
(WebKey.Use use) Determines if a header applies to a public JWK use case.static WebCryptoHeader.Param
Returns the enum constant of this class with the specified name.static WebCryptoHeader.Param[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
ALGORITHM
Encryption/signature algorithm. -
KEY_ID
Well-known key identifier. -
KEY_SET_URI
Well-known key set URI. -
KEY
Well-known public key. -
CERTIFICATE_URI
Certificate chain URI. -
CERTIFICATE_CHAIN
Certificate chain. -
CERTIFICATE_THUMBPRINT
Certificate SHA-1 thumb print. -
CERTIFICATE_SHA256_THUMBPRINT
Certificate SHA-1 thumb print. -
TYPE
Signature/encryption media type. -
CONTENT_TYPE
Content media type. -
CRITICAL_PARAMS
Extended parameter names that must be included in the protected header. -
ENCRYPTION
Content encryption algorithm. -
ZIP
Plain-text compression algorithm for encryption. -
EPHEMERAL_PUBLIC_KEY
Ephemeral public key for key agreement algorithms.- See Also:
-
PARTY_UINFO
Public originator identifier (PartyUInfo) for key derivation.- See Also:
-
PARTY_VINFO
Public recipient identifier (PartyVInfo) for key derivation.- See Also:
-
INITIALIZATION_VECTOR
Initialization vector for GCM key wrap.- See Also:
-
TAG
Authentication tag for GCM key wrap.- See Also:
-
PASSWORD_SALT
Password salt for use with PBES2.- See Also:
-
PASSWORD_COUNT
PBKDF2 iteration count for use with PBES2.- See Also:
-
-
Field Details
-
name
JOSE standard parameter name. -
required
public final boolean requiredIndicates if the parameter is required for this algorithm.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
from
Gets a parameter by JOSE standard parameter name.- Parameters:
name
- JOSE standard name- Returns:
WebCryptoHeader.Param
-
isPresent
Verifies that the header contains a non-null value.- Parameters:
header
- header- Returns:
- true if the value is present; else false
-
isUsedFor
Determines if a header applies to a public JWK use case.- Parameters:
use
- public key use- Returns:
- true if the header parameter is registered for the public JWK use case.
-
get
Gets the header value.- Parameters:
header
- header- Returns:
- header value
-