libssh: add support for SHA256 host public keys

Reported-by: Joshua Rogers
Fixes #21605

Closes #21607
This commit is contained in:
Viktor Szakats 2026-05-14 13:32:46 +02:00
parent 9135294115
commit eb9b253d66
No known key found for this signature in database
11 changed files with 85 additions and 48 deletions

View file

@ -2768,10 +2768,7 @@ static ParameterError opt_string(struct OperationConfig *config,
}
break;
case C_HOSTPUBSHA256: /* --hostpubsha256 */
if(!feature_libssh2)
err = PARAM_LIBCURL_DOESNT_SUPPORT;
else
err = getstr(&config->hostpubsha256, nextarg, DENY_BLANK);
err = getstr(&config->hostpubsha256, nextarg, DENY_BLANK);
break;
case C_TLSUSER: /* --tlsuser */
if(!feature_tls_srp)