Class AuthorizationCodeValidator
java.lang.Object
com.nimbusds.openid.connect.sdk.validators.AuthorizationCodeValidator
Authorisation code validator, using the
c_hash
ID token claim.
Required in the hybrid flow where the authorisation code is returned
together with an ID token at the authorisation endpoint.
Related specifications:
- OpenID Connect Core 1.0, section 3.3.2.10.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic void
validate
(AuthorizationCode code, com.nimbusds.jose.JWSAlgorithm jwsAlgorithm, CodeHash codeHash) Validates the specified authorisation code.
-
Constructor Details
-
AuthorizationCodeValidator
public AuthorizationCodeValidator()
-
-
Method Details
-
validate
public static void validate(AuthorizationCode code, com.nimbusds.jose.JWSAlgorithm jwsAlgorithm, CodeHash codeHash) throws InvalidHashException Validates the specified authorisation code.- Parameters:
code
- The authorisation code. Must not benull
.jwsAlgorithm
- The JWS algorithm of the ID token. Must not benull
.=codeHash
- The authorisation code hash, as set in thec_hash
ID token claim. Must not benull
.- Throws:
InvalidHashException
- If the authorisation code doesn't match the hash.
-