Skip to content
Snippets Groups Projects

fix: a few certification patches

Merged Feodor Alexandrov requested to merge gamayun-fixes into master
All threads resolved!
12 files
+ 483
1
Compare changes
  • Side-by-side
  • Inline
Files
12
+ 17
0
diff --git a/lib/vssh/libssh2.c b/lib/vssh/libssh2.c
index ce9229f8f..4aef2ae70 100644
--- a/lib/vssh/libssh2.c
+++ b/lib/vssh/libssh2.c
@@ -723,11 +723,11 @@ static CURLcode ssh_check_fingerprint(struct Curl_easy *data)
*/
if((pub_pos != b64_pos) ||
strncmp(fingerprint_b64, pubkey_sha256, pub_pos)) {
- free(fingerprint_b64);
failf(data,
"Denied establishing ssh session: mismatch sha256 fingerprint. "
"Remote %s is not equal to %s", fingerprint_b64, pubkey_sha256);
+ free(fingerprint_b64);
state(data, SSH_SESSION_FREE);
sshc->actualcode = CURLE_PEER_FAILED_VERIFICATION;
return sshc->actualcode;
Loading