1
0
Fork 0
mirror of git://git.gnupg.org/gnupg.git synced 2025-07-02 22:46:30 +02:00

experiment: Fix keygrip computation for new 448 key on gpg-agent.

Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
This commit is contained in:
NIIBE Yutaka 2021-10-08 22:25:05 +09:00
parent f2b54b3309
commit e6002e16c9
4 changed files with 37 additions and 24 deletions

View file

@ -1805,11 +1805,13 @@ pubkey_nbits( int algo, gcry_mpi_t *key )
rc = gpg_error_from_syserror ();
else
{
gcry_mpi_t pubkey = openpgp_ecc_parse_pubkey (algo, curve, key[1]);
const char *curve_name = openpgp_oid_to_curve (curve, 1);
gcry_mpi_t pubkey = openpgp_ecc_parse_pubkey (algo,
curve_name, key[1]);
rc = gcry_sexp_build (&sexp, NULL,
"(public-key(ecc(curve%s)(q%m)))",
curve, key[1]);
curve_name, key[1]);
xfree (curve);
gcry_mpi_release (pubkey);
}