Class PlainAuthenticationState

java.lang.Object
com.icegreen.greenmail.smtp.auth.PlainAuthenticationState
All Implemented Interfaces:
AuthenticationState, UsernameAuthentication

public class PlainAuthenticationState extends Object implements AuthenticationState, UsernameAuthentication
Details from the AuthCommand.AuthMechanism.PLAIN authorization mechanism, when that mechanism was used for authentication.
  • Constructor Details

    • PlainAuthenticationState

      public PlainAuthenticationState(SaslMessage saslMessage)
      Parameters:
      saslMessage - The parsed message sent by the client with the AUTH command.
    • PlainAuthenticationState

      public PlainAuthenticationState(String authorizationId, String authenticationId, String password)
      Parameters:
      authorizationId - The authorization ID sent by the client with the AUTH command.
      authenticationId - The authentication ID sent by the client with the AUTH command.
      password - The password sent by the client with the AUTH command.
  • Method Details

    • getType

      public String getType()
      Specified by:
      getType in interface AuthenticationState
      Returns:
      The type of the used authentication mechanism, e.g. PLAIN or LOGIN.
    • getAuthorizationId

      public String getAuthorizationId()
      Returns:
      The authorization ID sent by the client with the AUTH command.
    • getAuthenticationId

      public String getAuthenticationId()
      Returns:
      The authentication ID sent by the client with the AUTH command.
    • getPassword

      public String getPassword()
      Returns:
      password The password sent by the client with the AUTH command.
    • getUsername

      public String getUsername()
      Specified by:
      getUsername in interface UsernameAuthentication