Package org.kie.kogito.auth
Interface IdentityProvider
public interface IdentityProvider
Delivers security information about given identity that includes name and assigned roles.
-
Method Summary
-
Method Details
-
getName
String getName()Returns name assigned to the current context, usually refers to the username- Returns:
- assigned name taken from security context
-
getRoles
Collection<String> getRoles()Returns roles assigned to the current context if any- Returns:
- Collection of assigned roles or empty one
-
hasRole
Checks if given role is assigned to current context- Parameters:
role- role to be checked- Returns:
- true if the role is found otherwise null
-