зеркало из https://github.com/github/putty.git
Fix text name of hmac-sha1-96-buggy.
I carefully set up separate mechanisms for the "-96" suffix on the
hash name and the "bug-compatible" in parens after it, so that the
latter could share its parens with annotations from the underlying
hash. And then I forgot to _use_ the second mechanism!
Also added ssh2_mac_text_name to the testcrypt API so I could check it
easily. The result before this fix:
>>> ssh2_mac_text_name(ssh2_mac_new("hmac_sha1_96_buggy", None))
'HMAC-SHA-1-96 (bug-compatible) (unaccelerated)'
And after, which is what I intended all along:
>>> ssh2_mac_text_name(ssh2_mac_new("hmac_sha1_96_buggy", None))
'HMAC-SHA-1-96 (bug-compatible, unaccelerated)'
(cherry picked from commit 600bf247d3
)
This commit is contained in:
Родитель
14c6ddca63
Коммит
f7a3280e27
|
@ -222,7 +222,7 @@ const ssh2_macalg ssh_hmac_sha1_96 = {
|
|||
};
|
||||
|
||||
const struct hmac_extra ssh_hmac_sha1_buggy_extra = {
|
||||
&ssh_sha1, " (bug-compatible)"
|
||||
&ssh_sha1, "", "bug-compatible"
|
||||
};
|
||||
|
||||
const ssh2_macalg ssh_hmac_sha1_buggy = {
|
||||
|
@ -233,7 +233,7 @@ const ssh2_macalg ssh_hmac_sha1_buggy = {
|
|||
};
|
||||
|
||||
const struct hmac_extra ssh_hmac_sha1_96_buggy_extra = {
|
||||
&ssh_sha1, "-96 (bug-compatible)"
|
||||
&ssh_sha1, "-96", "bug-compatible"
|
||||
};
|
||||
|
||||
const ssh2_macalg ssh_hmac_sha1_96_buggy = {
|
||||
|
|
|
@ -136,6 +136,7 @@ FUNC2(void, ssh2_mac_setkey, val_mac, val_string_ptrlen)
|
|||
FUNC1(void, ssh2_mac_start, val_mac)
|
||||
FUNC2(void, ssh2_mac_update, val_mac, val_string_ptrlen)
|
||||
FUNC1(val_string, ssh2_mac_genresult, val_mac)
|
||||
FUNC1(val_string_asciz_const, ssh2_mac_text_name, val_mac)
|
||||
|
||||
/*
|
||||
* The ssh_key abstraction. All the uses of BinarySink and
|
||||
|
|
Загрузка…
Ссылка в новой задаче