diff options
author | Aris Adamantiadis <aris@0xbadc0de.be> | 2013-07-13 18:12:10 +0200 |
---|---|---|
committer | Aris Adamantiadis <aris@0xbadc0de.be> | 2013-07-13 18:12:10 +0200 |
commit | 3b81da21c2a515cac146bdf164ccc32ad83fc069 (patch) | |
tree | 14e07e3583557464b8dc39d6a8d17da5e1c62d69 /src | |
parent | ed7e3c936b53cd6a26571274be7f9340b4de1770 (diff) | |
download | libssh-3b81da21c2a515cac146bdf164ccc32ad83fc069.tar.gz libssh-3b81da21c2a515cac146bdf164ccc32ad83fc069.tar.xz libssh-3b81da21c2a515cac146bdf164ccc32ad83fc069.zip |
DH: fix rekeying when using aes256 and bigger
Diffstat (limited to 'src')
-rw-r--r-- | src/dh.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -983,7 +983,7 @@ int generate_session_keys(ssh_session session) { goto error; } ssh_mac_update(ctx, k_string, ssh_string_len(k_string) + 4); - ssh_mac_update(ctx, crypto->session_id, + ssh_mac_update(ctx, crypto->secret_hash, crypto->digest_len); ssh_mac_update(ctx, crypto->encryptkey, crypto->digest_len); ssh_mac_final(crypto->encryptkey + crypto->digest_len, ctx); @@ -995,7 +995,7 @@ int generate_session_keys(ssh_session session) { goto error; ctx = ssh_mac_ctx_init(crypto->mac_type); ssh_mac_update(ctx, k_string, ssh_string_len(k_string) + 4); - ssh_mac_update(ctx, crypto->session_id, + ssh_mac_update(ctx, crypto->secret_hash, crypto->digest_len); ssh_mac_update(ctx, crypto->decryptkey, crypto->digest_len); ssh_mac_final(crypto->decryptkey + crypto->digest_len, ctx); |