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:
@ -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"
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user