Interface AuthenticationState.Succeeded

All Superinterfaces:
AuthenticationState, Request.AuthenticationState
All Known Implementing Classes:
LoginAuthenticator.UserAuthenticationSent, LoginAuthenticator.UserAuthenticationSucceeded, SessionAuthentication
Enclosing interface:
AuthenticationState

public static interface AuthenticationState.Succeeded extends AuthenticationState
A successful Authentication with User information.
  • Method Details

    • getAuthenticationType

      String getAuthenticationType()
      Returns:
      The method used to authenticate the user.
    • getUserIdentity

      UserIdentity getUserIdentity()
      Returns:
      The UserIdentity of the authenticated user.
    • getUserPrincipal

      default Principal getUserPrincipal()
      Specified by:
      getUserPrincipal in interface Request.AuthenticationState
      Returns:
      The authenticated user Principal, or null if the Authentication is in a non-authenticated state.
    • isUserInRole

      boolean isUserInRole(String role)
      Parameters:
      role - The role to check.
      Returns:
      True if the user is in the passed role
    • logout

      void logout(Request request, Response response)
      Remove any user information that may be present in the request such that a call to getUserPrincipal/getRemoteUser will return null.
      Parameters:
      request - the request
      response - the response