Package org.jose4j.jwk
Class JsonWebKey
java.lang.Object
org.jose4j.jwk.JsonWebKey
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
OctetSequenceJsonWebKey,PublicJsonWebKey
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic enum -
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedJsonWebKey(Key key) protectedJsonWebKey(Map<String, Object> params) -
Method Summary
Modifier and TypeMethodDescriptioncalculateBase64urlEncodedThumbprint(String hashAlgorithm) byte[]calculateThumbprint(String hashAlgorithm) calculateThumbprintUri(String hashAlgorithm) protected abstract voidfillTypeSpecificParams(Map<String, Object> params, JsonWebKey.OutputControlLevel outputLevel) getKey()getKeyId()abstract String<T> TgetOtherParameterValue(String name, Class<T> type) Deprecated.protected static Stringprotected static Stringprotected static StringgetStringRequired(Map<String, Object> params, String name) getUse()protected abstract Stringprotected voidprotected voidremoveFromOtherParams(String... names) voidsetAlgorithm(String algorithm) voidvoidvoidsetOtherParameter(String name, Object value) voidtoJson()toJson(JsonWebKey.OutputControlLevel outputLevel) toParams(JsonWebKey.OutputControlLevel outputLevel) toString()
-
Field Details
-
KEY_TYPE_PARAMETER
- See Also:
-
USE_PARAMETER
- See Also:
-
KEY_ID_PARAMETER
- See Also:
-
ALGORITHM_PARAMETER
- See Also:
-
KEY_OPERATIONS
- See Also:
-
otherParameters
-
key
-
-
Constructor Details
-
JsonWebKey
-
JsonWebKey
- Throws:
JoseException
-
-
Method Details
-
getKeyType
-
fillTypeSpecificParams
protected abstract void fillTypeSpecificParams(Map<String, Object> params, JsonWebKey.OutputControlLevel outputLevel) -
getPublicKey
Deprecated.deprecated in favorgetKey()orPublicJsonWebKey.getPublicKey()- Returns:
- PublicKey
-
getKey
-
getUse
-
setUse
-
getKeyId
-
setKeyId
-
getAlgorithm
-
setAlgorithm
-
getKeyOps
-
setKeyOps
-
setOtherParameter
-
getOtherParameterValue
-
removeFromOtherParams
-
toParams
-
toJson
-
toJson
-
toString
-
calculateBase64urlEncodedThumbprint
-
calculateThumbprint
-
calculateThumbprintUri
-
produceThumbprintHashInput
-
putIfNotNull
-
getString
- Throws:
JoseException
-
getStringRequired
protected static String getStringRequired(Map<String, Object> params, String name) throws JoseException- Throws:
JoseException
-
getString
protected static String getString(Map<String, Object> params, String name, boolean required) throws JoseException- Throws:
JoseException
-
getKey()orPublicJsonWebKey.getPublicKey()