Listing of Source server/UserAuthenticationInterface.java
package se.entra.phantom.server;

/**
 * This interface must be supported by the user exit that handles
 * the user authentication.
 */
public interface UserAuthenticationInterface
{
  /**
   * Checks if UserID and Password is required for a particular
   * client IP-address.
   */
  public abstract boolean isUserIDPasswordRequired(ClientConnectionData ccd);

  /**
   * Verifies a UserID and Password entered on the client by a user.
   * Return null if OK, empty string to prompt user to change the
   * password or an error string that will be displayed on the client
   * side.
   */
  public abstract String verifyUserIDPassword(ClientConnectionData ccd,
                                              String password,
                                              int previousRetryCount);

  /**
   * Changes the password for a UserID.
   * Return null if OK or an error message string.
   */
  public abstract String changePassword(ClientConnectionData ccd,
                                        String oldPassword,
                                        String newPassword);

  /**
   * Upon an error for verifyUserIDPassword or changePassword,
   * this method is called to check if further retries should be
   * done, or if the client connection should be dropped.
   */
  public abstract boolean isRetryValid(ClientConnectionData ccd,
                                       int previousRetryCount);

  /**
   * Called to perform clean-up.
   */
  public abstract void dispose();
}