aboutsummaryrefslogtreecommitdiffstats
path: root/sm/certcheck.c
diff options
context:
space:
mode:
authorWerner Koch <[email protected]>2007-05-07 19:49:12 +0000
committerWerner Koch <[email protected]>2007-05-07 19:49:12 +0000
commitd5052fd22864ebb879e3b417ecfefd88e6c1800a (patch)
tree82f547df2e3ac98021fd713f470cc00610482c8e /sm/certcheck.c
parentUpdated to automake 1.10. (diff)
downloadgnupg-d5052fd22864ebb879e3b417ecfefd88e6c1800a.tar.gz
gnupg-d5052fd22864ebb879e3b417ecfefd88e6c1800a.zip
Upgraded gettext.
Fixed accidental dependency on libgcrypt 1.3.0.
Diffstat (limited to 'sm/certcheck.c')
-rw-r--r--sm/certcheck.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/sm/certcheck.c b/sm/certcheck.c
index 6dbc72d64..0a362d3fb 100644
--- a/sm/certcheck.c
+++ b/sm/certcheck.c
@@ -35,6 +35,11 @@
#include "keydb.h"
#include "i18n.h"
+
+/* Remove this if libgcrypt 1.3.0 is required. */
+#define MY_GCRY_PK_ECDSA 301
+
+
/* Return the number of bits of the Q parameter from the DSA key
KEY. */
static unsigned int
@@ -72,11 +77,11 @@ do_encode_md (gcry_md_hd_t md, int algo, int pkalgo, unsigned int nbits,
size_t nframe;
unsigned char *frame;
- if (pkalgo == GCRY_PK_DSA || pkalgo == GCRY_PK_ECDSA)
+ if (pkalgo == GCRY_PK_DSA || pkalgo == MY_GCRY_PK_ECDSA)
{
unsigned int qbits;
- if ( pkalgo == GCRY_PK_ECDSA )
+ if ( pkalgo == MY_GCRY_PK_ECDSA )
qbits = gcry_pk_get_nbits (pkey);
else
qbits = get_dsa_qbits (pkey);
@@ -211,7 +216,7 @@ pk_algo_from_sexp (gcry_sexp_t pkey)
/* 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;
+ algo = MY_GCRY_PK_ECDSA;
else if (n==13 && !memcmp (name, "ambiguous-rsa", 13))
algo = GCRY_PK_RSA;
else