summaryrefslogtreecommitdiffstats
path: root/sm/keylist.c
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2023-10-24 14:22:05 +0200
committerWerner Koch <wk@gnupg.org>2023-10-24 14:22:32 +0200
commit97708e2ac72253fa1ddbcde63b23095ac2d1604f (patch)
treea3a953ba1eb719ac43d9f88b2bf10e70aa97e394 /sm/keylist.c
parentcommon: Provide API to parse BER/TLV encodings. (diff)
downloadgnupg2-97708e2ac72253fa1ddbcde63b23095ac2d1604f.tar.xz
gnupg2-97708e2ac72253fa1ddbcde63b23095ac2d1604f.zip
sm: Flag Brainpool curves as compliant.
* sm/keylist.c (print_compliance_flags): Add arg curve. (list_cert_colon): Pass curve to the compliance check. -- GnuPG-bug-id: 6253
Diffstat (limited to '')
-rw-r--r--sm/keylist.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sm/keylist.c b/sm/keylist.c
index d6eccfc45..e84eb31d3 100644
--- a/sm/keylist.c
+++ b/sm/keylist.c
@@ -430,7 +430,7 @@ email_kludge (const char *name)
* number. NBITS is the length of the key in bits. */
static void
print_compliance_flags (ksba_cert_t cert, int algo, unsigned int nbits,
- estream_t fp)
+ const char *curvename, estream_t fp)
{
int indent = 0;
int hashalgo;
@@ -438,7 +438,7 @@ print_compliance_flags (ksba_cert_t cert, int algo, unsigned int nbits,
/* Note that we do not need to test for PK_ALGO_FLAG_RSAPSS because
* that is not a property of the key but one of the created
* signature. */
- if (gnupg_pk_is_compliant (CO_DE_VS, algo, 0, NULL, nbits, NULL))
+ if (gnupg_pk_is_compliant (CO_DE_VS, algo, 0, NULL, nbits, curvename))
{
hashalgo = gcry_md_map_name (ksba_cert_get_digest_algo (cert));
if (gnupg_digest_is_compliant (CO_DE_VS, hashalgo))
@@ -629,7 +629,7 @@ list_cert_colon (ctrl_t ctrl, ksba_cert_t cert, unsigned int validity,
if (curve)
es_fputs (curve, fp);
es_putc (':', fp); /* End of field 17. */
- print_compliance_flags (cert, algo, nbits, fp);
+ print_compliance_flags (cert, algo, nbits, curve, fp);
es_putc (':', fp); /* End of field 18. */
es_putc ('\n', fp);