diff options
author | NIIBE Yutaka <gniibe@fsij.org> | 2022-07-07 12:13:08 +0900 |
---|---|---|
committer | NIIBE Yutaka <gniibe@fsij.org> | 2022-07-07 12:13:08 +0900 |
commit | b2a64ed4f34abbd3871336503bec5ffeb3ad547b (patch) | |
tree | 23fbf2c35906a33d803c32661a9480bd46e5f168 /tests | |
parent | 37b812f5e2a3c80d4bc104512248a07268f3c98b (diff) | |
download | libgcrypt-b2a64ed4f34abbd3871336503bec5ffeb3ad547b.tar.gz |
cipher: Fix gcry_pk_hash_verify for explicit hash.
* cipher/pubkey.c (_gcry_pk_verify_md): Implement support of explicit
hash.
* tests/t-ecdsa.c (one_test_sexp): Use explicit hash.
--
GnuPG-bug-id: 6066
Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/t-ecdsa.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/tests/t-ecdsa.c b/tests/t-ecdsa.c index 725fcb4f..d36d217b 100644 --- a/tests/t-ecdsa.c +++ b/tests/t-ecdsa.c @@ -487,10 +487,7 @@ one_test_sexp (const char *curvename, const char *sha_alg, fail ("gcry_pk_hash_verify failed for test: %s", gpg_strerror (err)); - /* TODO Verifying with data_tmpl2 crashes because gcry_pk_hash_verify() - * does not support specifying the hash algorithm explicitly. See - * https://dev.gnupg.org/T6066, which tracks this problem. */ - err = gcry_pk_hash_verify (s_sig2, data_tmpl, s_pk, hd, ctx); + err = gcry_pk_hash_verify (s_sig2, data_tmpl2, s_pk, hd, ctx); if (err) fail ("gcry_pk_hash_verify with explicit hash algorithm %s failed: %s", gcry_md_algo_name (md_algo), gpg_strerror (err)); |