Serializable, Comparable<Identifier>, net.minidev.json.JSONAwareAccessTokenHash, CodeHash, StateHashpublic abstract class HashClaim extends Identifier
DEFAULT_BYTE_LENGTH| Modifier | Constructor | Description |
|---|---|---|
protected |
HashClaim(String value) |
Creates a new SHA-2 based claim with the specified value.
|
| Modifier and Type | Method | Description |
|---|---|---|
static String |
computeValue(Identifier identifier,
com.nimbusds.jose.JWSAlgorithm alg) |
Computes the SHA-2 claim value for the specified identifier.
|
static MessageDigest |
getMessageDigestInstance(com.nimbusds.jose.JWSAlgorithm alg) |
Gets the matching SHA-2 message digest for the specified JSON Web
Signature (JWS) algorithm.
|
compareTo, equals, getValue, hashCode, toJSONString, toStringpublic static MessageDigest getMessageDigestInstance(com.nimbusds.jose.JWSAlgorithm alg)
alg - The JWS algorithm. Must not be null.null if the JWS algorithm
or its corresponding SHA-2 message digest are not supported.public static String computeValue(Identifier identifier, com.nimbusds.jose.JWSAlgorithm alg)
identifier - The identifier, typically an authorisation code or
an access token. Must not be null.alg - The reference JSON Web Signature (JWS) algorithm.
Must not be null.null if the JWS algorithm or its corresponding
SHA-2 message digest are not supported.Copyright © 2018 Connect2id Ltd.. All rights reserved.