Interface PasswordAuthenticationReporter


  • public interface PasswordAuthenticationReporter
    Used to inform the about the progress of a password authentication
    See Also:
    RFC-4252 section 8
    • Method Detail

      • signalAuthenticationAttempt

        default void signalAuthenticationAttempt​(ClientSession session,
                                                 java.lang.String service,
                                                 java.lang.String oldPassword,
                                                 boolean modified,
                                                 java.lang.String newPassword)
                                          throws java.lang.Exception
        Parameters:
        session - The ClientSession
        service - The requesting service name
        oldPassword - The password being attempted
        modified - true if this is an attempt due to SSH_MSG_USERAUTH_PASSWD_CHANGEREQ
        newPassword - The changed password
        Throws:
        java.lang.Exception - If failed to handle the callback - Note: may cause session close
      • signalAuthenticationExhausted

        default void signalAuthenticationExhausted​(ClientSession session,
                                                   java.lang.String service)
                                            throws java.lang.Exception
        Signals end of passwords attempts and optionally switching to other authentication methods. Note: neither signalAuthenticationSuccess nor signalAuthenticationFailure are invoked.
        Parameters:
        session - The ClientSession
        service - The requesting service name
        Throws:
        java.lang.Exception - If failed to handle the callback - Note: may cause session close
      • signalAuthenticationSuccess

        default void signalAuthenticationSuccess​(ClientSession session,
                                                 java.lang.String service,
                                                 java.lang.String password)
                                          throws java.lang.Exception
        Parameters:
        session - The ClientSession
        service - The requesting service name
        password - The password that was attempted
        Throws:
        java.lang.Exception - If failed to handle the callback - Note: may cause session close
      • signalAuthenticationFailure

        default void signalAuthenticationFailure​(ClientSession session,
                                                 java.lang.String service,
                                                 java.lang.String password,
                                                 boolean partial,
                                                 java.util.List<java.lang.String> serverMethods)
                                          throws java.lang.Exception
        Parameters:
        session - The ClientSession
        service - The requesting service name
        password - The password that was attempted
        partial - true if some partial authentication success so far
        serverMethods - The List of authentication methods that can continue
        Throws:
        java.lang.Exception - If failed to handle the callback - Note: may cause session close