1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-02 03:52:49 -05:00

Add a key-length field to 'struct ssh_mac'.

The key derivation code has been assuming (though non-critically, as
it happens) that the size of the MAC output is the same as the size of
the MAC key. That isn't even a good assumption for the HMAC family,
due to HMAC-SHA1-96 and also the bug-compatible versions of HMAC-SHA1
that only use 16 bytes of key material; so now we have an explicit
key-length field separate from the MAC-length field.
This commit is contained in:
Simon Tatham
2015-08-21 23:20:12 +01:00
parent 1df12e3915
commit 42cf086b6b
6 changed files with 10 additions and 10 deletions

View File

@ -345,7 +345,7 @@ const struct ssh_mac ssh_hmac_sha256 = {
hmacsha256_start, hmacsha256_bytes,
hmacsha256_genresult, hmacsha256_verresult,
"hmac-sha2-256", "hmac-sha2-256-etm@openssh.com",
32,
32, 32,
"HMAC-SHA-256"
};