[svn] GnuPG - r4486 - trunk/sm
svn author wk
cvs at cvs.gnupg.org
Wed Apr 18 15:03:37 CEST 2007
Author: wk
Date: 2007-04-18 15:03:35 +0200 (Wed, 18 Apr 2007)
New Revision: 4486
Modified:
trunk/sm/ChangeLog
trunk/sm/certcheck.c
Log:
sm/
* certcheck.c (do_encode_md): Support 160 bit ECDSA.
Modified: trunk/sm/ChangeLog
===================================================================
--- trunk/sm/ChangeLog 2007-04-17 04:00:38 UTC (rev 4485)
+++ trunk/sm/ChangeLog 2007-04-18 13:03:35 UTC (rev 4486)
@@ -1,3 +1,7 @@
+2007-04-18 Werner Koch <wk at g10code.com>
+
+ * certcheck.c (do_encode_md): Support 160 bit ECDSA.
+
2007-04-13 Werner Koch <wk at g10code.com>
* call-agent.c (start_agent): Don't use log_error when using the
Modified: trunk/sm/certcheck.c
===================================================================
--- trunk/sm/certcheck.c 2007-04-17 04:00:38 UTC (rev 4485)
+++ trunk/sm/certcheck.c 2007-04-18 13:03:35 UTC (rev 4486)
@@ -44,7 +44,7 @@
size_t nframe;
unsigned char *frame;
- if (pkalgo == GCRY_PK_DSA)
+ if (pkalgo == GCRY_PK_DSA || pkalgo == GCRY_PK_ECDSA)
{
nframe = gcry_md_get_algo_dlen (algo);
if (nframe != 20)
@@ -143,6 +143,12 @@
algo = GCRY_PK_RSA;
else if (n==3 && !memcmp (name, "dsa", 3))
algo = GCRY_PK_DSA;
+ else if (n==5 && !memcmp (name, "ecdsa", 5))
+ algo = GCRY_PK_ECDSA;
+ /* Because this function is called only for verification we can
+ assume that ECC actually means ECDSA. */
+ else if (n==3 && !memcmp (name, "ecc", 3))
+ algo = GCRY_PK_ECDSA;
else if (n==13 && !memcmp (name, "ambiguous-rsa", 13))
algo = GCRY_PK_RSA;
else
More information about the Gnupg-commits
mailing list