public final class JwtValidator extends Object
JwtValidator
is responsible for the JWT validation. Constraints could be applied using
the Builder
to several claims in order to verify the claim's value (expiration, presence, etc.).
The JwtValidator
is stateless and immutable therefore, it can be reused to apply the same set
of constraints to another Jwt
.Modifier and Type | Class and Description |
---|---|
static class |
JwtValidator.Builder
Builder for the JwtValidator.
|
Modifier and Type | Method and Description |
---|---|
static JwtValidator.Builder |
builder()
Builder for the JwtValidator.
|
JwtValidatorResult |
report(Jwt jwt)
Returns the list of the violations, if any, raised by the validation of the JWT.
|
public JwtValidatorResult report(Jwt jwt)
jwt
- The given JWT to analyze.Violation
s, if any, raised by the validation of the JWT.public static JwtValidator.Builder builder()
Copyright 2011-2017 ForgeRock AS.