Interface AuthenticationInfo
- All Known Implementing Classes:
BasicAuthenticationInfo
,JwtTokenAuthenticationInfo
,JwtTokenWithForwardJwtAuthenticationInfo
public interface AuthenticationInfo
The
AuthenticationInfo
provides access to the authorization of the current request.
Usually UserInfoProvider
react on a specific AuthenticationInfo
implementations to extract user (principal) information from the authentication.
The AuthenticationInfo
can also be used to enable principal propagation of the current user in the request to a different service, as it provides access to the original authentication.-
Method Summary
Modifier and TypeMethodDescriptiondefault <T extends AuthenticationInfo>
TCan be used to cast theAuthenticationInfo
to a specific implementation: -BasicAuthenticationInfo
-JwtTokenAuthenticationInfo
-JwtTokenWithForwardJwtAuthenticationInfo
default boolean
is
(Class<? extends AuthenticationInfo> clazz) Can be used to check if anAuthenticationInfo
is an instance of the commonAuthenticationInfo
implementations: -BasicAuthenticationInfo
-JwtTokenAuthenticationInfo
-JwtTokenWithForwardJwtAuthenticationInfo
-
Method Details
-
is
Can be used to check if anAuthenticationInfo
is an instance of the commonAuthenticationInfo
implementations: -BasicAuthenticationInfo
-JwtTokenAuthenticationInfo
-JwtTokenWithForwardJwtAuthenticationInfo
- Parameters:
clazz
- the class to check the instance against- Returns:
- true, if the
AuthenticationInfo
is of an instance ofclazz
-
as
Can be used to cast theAuthenticationInfo
to a specific implementation: -BasicAuthenticationInfo
-JwtTokenAuthenticationInfo
-JwtTokenWithForwardJwtAuthenticationInfo
- Type Parameters:
T
- the type of the class- Parameters:
clazz
- the class to cast the instance to- Returns:
- the instance casted to type
T
-