Details
-
Bug
-
Status: Open
-
Minor
-
Resolution: Unresolved
-
2.2.0
-
None
-
SSHD version:2.2.0
Java version:openjdk version "11.0.7" 2020-04-14
Description
Keyboard-interactive authentication sent SSH_MSG_USERAUTH_REQUEST twice even though we set SshClient ClientAuthenticationManager.PASSWORD_PROMPTS to 1
Here is console output from ssh command line client. Incorrect password is provided
$ssh -vv -o PreferredAuthentications=keyboard-interactive -o NumberOfPasswordPrompts=1 user@localhost
...
debug2: service_accept: ssh-userauth
debug1: SSH2_MSG_SERVICE_ACCEPT received
some banner
debug1: Authentications that can continue: publickey,keyboard-interactive
debug1: Next authentication method: keyboard-interactive
debug2: userauth_kbdint
debug2: we sent a keyboard-interactive packet, wait for reply
debug2: input_userauth_info_req
debug2: input_userauth_info_req: num_prompts 1
Password:
debug1: Authentications that can continue: publickey,keyboard-interactive
debug2: we did not send a packet, disable method
debug1: No more authentication methods to try.
localhost: Permission denied (publickey,keyboard-interactive).
But in UserAuthenticationManager.java, another SSH_MSG_USERAUTH_REQUEST was send before processing SSH_MSG_USERAUTH_FAILURE.