curl/lib/vssh
Jay Satiro 80fc040e45 libssh2: fix error message on failed pubkey-from-file
- If libssh2_userauth_publickey_fromfile_ex returns -1 then show error
  message "SSH public key authentication failed: Reason unknown (-1)".

When libssh2_userauth_publickey_fromfile_ex returns -1 it does so as a
generic error and therefore doesn't set an error message. AFAICT that is
not documented behavior.

Prior to this change libcurl retrieved the last set error message which
would be from a previous function failing. That resulted in misleading
auth failed error messages in verbose mode.

Bug: https://github.com/curl/curl/issues/11837#issue-1891827355
Reported-by: consulion@users.noreply.github.com

Closes https://github.com/curl/curl/pull/11881
2023-09-21 02:59:21 -04:00
..
libssh2.c libssh2: fix error message on failed pubkey-from-file 2023-09-21 02:59:21 -04:00
libssh.c spelling: use 'reuse' not 're-use' in code and elsewhere 2023-08-23 23:22:36 +02:00
ssh.h libssh: use dynbuf instead of realloc 2023-03-16 23:32:22 +01:00
wolfssh.c spelling: use 'reuse' not 're-use' in code and elsewhere 2023-08-23 23:22:36 +02:00