public final class OidcIdTokenValidator
extends java.lang.Object
implements org.springframework.security.oauth2.core.OAuth2TokenValidator<org.springframework.security.oauth2.jwt.Jwt>
OAuth2TokenValidator responsible for validating the claims in an
ID Token.OAuth2TokenValidator,
Jwt,
ID Token
Validation| Constructor and Description |
|---|
OidcIdTokenValidator(ClientRegistration clientRegistration) |
| Modifier and Type | Method and Description |
|---|---|
void |
setClock(java.time.Clock clock)
Sets the
Clock used in Instant.now(Clock) when validating the
exp and iat claims. |
void |
setClockSkew(java.time.Duration clockSkew)
Sets the maximum acceptable clock skew.
|
org.springframework.security.oauth2.core.OAuth2TokenValidatorResult |
validate(org.springframework.security.oauth2.jwt.Jwt idToken) |
public OidcIdTokenValidator(ClientRegistration clientRegistration)
public org.springframework.security.oauth2.core.OAuth2TokenValidatorResult validate(org.springframework.security.oauth2.jwt.Jwt idToken)
validate in interface org.springframework.security.oauth2.core.OAuth2TokenValidator<org.springframework.security.oauth2.jwt.Jwt>public void setClockSkew(java.time.Duration clockSkew)
exp and
iat claims.clockSkew - the maximum acceptable clock skewpublic void setClock(java.time.Clock clock)
Clock used in Instant.now(Clock) when validating the
exp and iat claims.clock - the clock