Class UserAuthPassword

    • Constructor Detail

      • UserAuthPassword

        public UserAuthPassword()
    • Method Detail

      • sendPassword

        protected IoWriteFuture sendPassword​(Buffer buffer,
                                             ClientSession session,
                                             String oldPassword,
                                             String newPassword)
                                      throws Exception
        Sends the password via a SSH_MSG_USERAUTH_REQUEST message. If old and new password are not the same then it requests a password modification from the server (which may be denied if the server does not support this feature).
        Parameters:
        buffer - The Buffer to re-use for sending the message
        session - The target ClientSession
        oldPassword - The previous password
        newPassword - The new password
        Returns:
        An IoWriteFuture that can be used to wait and check on the success/failure of the request packet being sent
        Throws:
        Exception - If failed to send the message.
      • signalAuthMethodSuccess

        public void signalAuthMethodSuccess​(ClientSession session,
                                            String service,
                                            Buffer buffer)
                                     throws Exception
        Description copied from interface: UserAuth
        Signal reception of SSH_MSG_USERAUTH_SUCCESS message
        Parameters:
        session - The ClientSession
        service - The requesting service name
        buffer - The Buffer containing the success message (after having consumed the relevant data from it)
        Throws:
        Exception - If failed to handle the callback - Note: may cause session close
      • signalAuthMethodFailure

        public void signalAuthMethodFailure​(ClientSession session,
                                            String service,
                                            boolean partial,
                                            List<String> serverMethods,
                                            Buffer buffer)
                                     throws Exception
        Description copied from interface: UserAuth
        Signals reception of SSH_MSG_USERAUTH_FAILURE message
        Parameters:
        session - The ClientSession
        service - The requesting service name
        partial - true if some partial authentication success so far
        serverMethods - The List of authentication methods that can continue
        buffer - The Buffer containing the failure message (after having consumed the relevant data from it)
        Throws:
        Exception - If failed to handle the callback - Note: may cause session close