Class AADJwtClaimValidator<T>
- java.lang.Object
-
- com.azure.spring.aad.webapi.validator.AADJwtClaimValidator<T>
-
- All Implemented Interfaces:
org.springframework.security.oauth2.core.OAuth2TokenValidator<org.springframework.security.oauth2.jwt.Jwt>
public final class AADJwtClaimValidator<T> extends Object implements org.springframework.security.oauth2.core.OAuth2TokenValidator<org.springframework.security.oauth2.jwt.Jwt>
Validates a claim in aJwtagainst a providedPredicate. Note: Current implementation is not required, this is only used for compatibility with the Spring Boot 2.2.x version. Once support version is more than 2.2.X, then we can use "org.springframework.security.oauth2.jwt.JwtClaimValidator" instead.
-
-
Constructor Summary
Constructors Constructor Description AADJwtClaimValidator(String claim, Predicate<T> test)Constructs aAADJwtClaimValidatorusing the provided parameters
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.springframework.security.oauth2.core.OAuth2TokenValidatorResultvalidate(org.springframework.security.oauth2.jwt.Jwt token)
-
-
-
Constructor Detail
-
AADJwtClaimValidator
public AADJwtClaimValidator(String claim, Predicate<T> test)
Constructs aAADJwtClaimValidatorusing the provided parameters- Parameters:
claim- - is the name of the claim inJwtto validate.test- - is the predicate function for the claim to test against.
-
-
Method Detail
-
validate
public org.springframework.security.oauth2.core.OAuth2TokenValidatorResult validate(org.springframework.security.oauth2.jwt.Jwt token)
- Specified by:
validatein interfaceorg.springframework.security.oauth2.core.OAuth2TokenValidator<T>
-
-