Interface AuthenticationService

All Known Implementing Classes:
ApiKeyAuthenticationService, JwtAuthenticationService, LdapAuthenticationService, ManagedUserAuthenticationService, OidcAuthenticationService

public interface AuthenticationService
Interface that defines an authentication service.
Since:
1.0.0
Author:
Steve Springett
  • Method Summary

    Modifier and Type
    Method
    Description
    Defines an authentication method which returns a Principal if authentication is successful or an AuthorizationException if not.
    boolean
    Defines a method which returns if the specified piece of data, required to perform authentication is present.
  • Method Details

    • isSpecified

      boolean isSpecified()
      Defines a method which returns if the specified piece of data, required to perform authentication is present.
      Returns:
      true if the authentication data was specified, false if not
      Since:
      1.0.0
    • authenticate

      @Nullable Principal authenticate() throws AuthenticationException
      Defines an authentication method which returns a Principal if authentication is successful or an AuthorizationException if not.
      Returns:
      a Principal of the authenticated user
      Throws:
      AuthenticationException - an authentication failure
      Since:
      1.0.0