From 6bf8dfa073028374767cba684df9a06abd34a997 Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Mon, 29 Aug 2011 22:39:47 +0200 Subject: pki: Fix session_id hashing. I don't understand why this code worked before. It was completly wrong. --- src/pki.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/pki.c b/src/pki.c index 1ad01be3..7e86d307 100644 --- a/src/pki.c +++ b/src/pki.c @@ -1088,11 +1088,11 @@ ssh_string ssh_pki_do_sign(ssh_session session, return NULL; } - session_id = ssh_string_new(SHA_DIGEST_LEN); + session_id = ssh_string_new(crypto->digest_len); if (session_id == NULL) { return NULL; } - ssh_string_fill(session_id, crypto->session_id, SHA_DIGEST_LEN); + ssh_string_fill(session_id, crypto->session_id, crypto->digest_len); ctx = sha1_init(); if (ctx == NULL) { -- cgit