diff options
Diffstat (limited to 'sm')
-rw-r--r-- | sm/Makefile.am | 2 | ||||
-rw-r--r-- | sm/call-agent.c | 8 | ||||
-rw-r--r-- | sm/call-dirmngr.c | 4 | ||||
-rw-r--r-- | sm/certchain.c | 4 | ||||
-rw-r--r-- | sm/certcheck.c | 2 | ||||
-rw-r--r-- | sm/certdump.c | 2 | ||||
-rw-r--r-- | sm/certlist.c | 2 | ||||
-rw-r--r-- | sm/certreqgen-ui.c | 6 | ||||
-rw-r--r-- | sm/certreqgen.c | 2 | ||||
-rw-r--r-- | sm/decrypt.c | 2 | ||||
-rw-r--r-- | sm/delete.c | 2 | ||||
-rw-r--r-- | sm/encrypt.c | 2 | ||||
-rw-r--r-- | sm/export.c | 6 | ||||
-rw-r--r-- | sm/fingerprint.c | 2 | ||||
-rw-r--r-- | sm/gpgsm.c | 8 | ||||
-rw-r--r-- | sm/import.c | 6 | ||||
-rw-r--r-- | sm/keydb.c | 2 | ||||
-rw-r--r-- | sm/keylist.c | 22 | ||||
-rw-r--r-- | sm/misc.c | 4 | ||||
-rw-r--r-- | sm/qualified.c | 2 | ||||
-rw-r--r-- | sm/server.c | 4 | ||||
-rw-r--r-- | sm/sign.c | 2 | ||||
-rw-r--r-- | sm/verify.c | 2 |
23 files changed, 55 insertions, 43 deletions
diff --git a/sm/Makefile.am b/sm/Makefile.am index 4cfb246..ddc2e22 100644 --- a/sm/Makefile.am +++ b/sm/Makefile.am @@ -23,7 +23,7 @@ bin_PROGRAMS = gpgsm AM_CFLAGS = $(LIBGCRYPT_CFLAGS) $(KSBA_CFLAGS) $(LIBASSUAN_CFLAGS) -AM_CPPFLAGS = -I$(top_srcdir)/common -DKEYBOX_WITH_X509=1 +AM_CPPFLAGS = -DKEYBOX_WITH_X509=1 include $(top_srcdir)/am/cmacros.am if HAVE_W32_SYSTEM diff --git a/sm/call-agent.c b/sm/call-agent.c index 16a2497..0e47c14 100644 --- a/sm/call-agent.c +++ b/sm/call-agent.c @@ -33,11 +33,11 @@ #include "gpgsm.h" #include <gcrypt.h> #include <assuan.h> -#include "i18n.h" -#include "asshelp.h" +#include "../common/i18n.h" +#include "../common/asshelp.h" #include "keydb.h" /* fixme: Move this to import.c */ -#include "membuf.h" -#include "shareddefs.h" +#include "../common/membuf.h" +#include "../common/shareddefs.h" #include "passphrase.h" diff --git a/sm/call-dirmngr.c b/sm/call-dirmngr.c index 45303e8..5ee15b7 100644 --- a/sm/call-dirmngr.c +++ b/sm/call-dirmngr.c @@ -32,9 +32,9 @@ #include <gcrypt.h> #include <assuan.h> -#include "i18n.h" +#include "../common/i18n.h" #include "keydb.h" -#include "asshelp.h" +#include "../common/asshelp.h" struct membuf { diff --git a/sm/certchain.c b/sm/certchain.c index b3e8656..a361aca 100644 --- a/sm/certchain.c +++ b/sm/certchain.c @@ -34,8 +34,8 @@ #include "keydb.h" #include "../kbx/keybox.h" /* for KEYBOX_FLAG_* */ -#include "i18n.h" -#include "tlv.h" +#include "../common/i18n.h" +#include "../common/tlv.h" /* Object to keep track of certain root certificates. */ diff --git a/sm/certcheck.c b/sm/certcheck.c index 04b3917..1102bcc 100644 --- a/sm/certcheck.c +++ b/sm/certcheck.c @@ -31,7 +31,7 @@ #include <ksba.h> #include "keydb.h" -#include "i18n.h" +#include "../common/i18n.h" /* Return the number of bits of the Q parameter from the DSA key diff --git a/sm/certdump.c b/sm/certdump.c index bd37da4..edee76f 100644 --- a/sm/certdump.c +++ b/sm/certdump.c @@ -37,7 +37,7 @@ #include <ksba.h> #include "keydb.h" -#include "i18n.h" +#include "../common/i18n.h" struct dn_array_s { diff --git a/sm/certlist.c b/sm/certlist.c index bfc35ce..e493cda 100644 --- a/sm/certlist.c +++ b/sm/certlist.c @@ -32,7 +32,7 @@ #include <ksba.h> #include "keydb.h" -#include "i18n.h" +#include "../common/i18n.h" static const char oid_kp_serverAuth[] = "1.3.6.1.5.5.7.3.1"; diff --git a/sm/certreqgen-ui.c b/sm/certreqgen-ui.c index b50d338..9772a3b 100644 --- a/sm/certreqgen-ui.c +++ b/sm/certreqgen-ui.c @@ -29,9 +29,9 @@ #include "gpgsm.h" #include <gcrypt.h> -#include "i18n.h" -#include "ttyio.h" -#include "membuf.h" +#include "../common/i18n.h" +#include "../common/ttyio.h" +#include "../common/membuf.h" /* Prompt for lines and append them to MB. */ diff --git a/sm/certreqgen.c b/sm/certreqgen.c index fe35ea8..4431870 100644 --- a/sm/certreqgen.c +++ b/sm/certreqgen.c @@ -66,7 +66,7 @@ #include <ksba.h> #include "keydb.h" -#include "i18n.h" +#include "../common/i18n.h" enum para_name diff --git a/sm/decrypt.c b/sm/decrypt.c index cda4d29..976bd12 100644 --- a/sm/decrypt.c +++ b/sm/decrypt.c @@ -31,7 +31,7 @@ #include <ksba.h> #include "keydb.h" -#include "i18n.h" +#include "../common/i18n.h" struct decrypt_filter_parm_s { diff --git a/sm/delete.c b/sm/delete.c index 3536968..56d5b1f 100644 --- a/sm/delete.c +++ b/sm/delete.c @@ -31,7 +31,7 @@ #include <ksba.h> #include "keydb.h" -#include "i18n.h" +#include "../common/i18n.h" /* Delete a certificate or an secret key from a key database. */ diff --git a/sm/encrypt.c b/sm/encrypt.c index 3a7d4bb..c43a9e6 100644 --- a/sm/encrypt.c +++ b/sm/encrypt.c @@ -32,7 +32,7 @@ #include <ksba.h> #include "keydb.h" -#include "i18n.h" +#include "../common/i18n.h" struct dek_s { diff --git a/sm/export.c b/sm/export.c index d721d52..29a5ac3 100644 --- a/sm/export.c +++ b/sm/export.c @@ -31,9 +31,9 @@ #include <ksba.h> #include "keydb.h" -#include "exechelp.h" -#include "i18n.h" -#include "sysutils.h" +#include "../common/exechelp.h" +#include "../common/i18n.h" +#include "../common/sysutils.h" #include "minip12.h" /* A table to store a fingerprint as used in a duplicates table. We diff --git a/sm/fingerprint.c b/sm/fingerprint.c index d8e8405..fbcec58 100644 --- a/sm/fingerprint.c +++ b/sm/fingerprint.c @@ -31,7 +31,7 @@ #include <gcrypt.h> #include <ksba.h> -#include "host2net.h" +#include "../common/host2net.h" /* Return the fingerprint of the certificate (we can't put this into @@ -35,11 +35,11 @@ #include "passphrase.h" #include "../common/shareddefs.h" #include "../kbx/keybox.h" /* malloc hooks */ -#include "i18n.h" +#include "../common/i18n.h" #include "keydb.h" -#include "sysutils.h" -#include "gc-opt-flags.h" -#include "asshelp.h" +#include "../common/sysutils.h" +#include "../common/gc-opt-flags.h" +#include "../common/asshelp.h" #include "../common/init.h" diff --git a/sm/import.c b/sm/import.c index b284b51..c7b65ad 100644 --- a/sm/import.c +++ b/sm/import.c @@ -31,9 +31,9 @@ #include <ksba.h> #include "keydb.h" -#include "exechelp.h" -#include "i18n.h" -#include "sysutils.h" +#include "../common/exechelp.h" +#include "../common/i18n.h" +#include "../common/sysutils.h" #include "../kbx/keybox.h" /* for KEYBOX_FLAG_* */ #include "../common/membuf.h" #include "minip12.h" @@ -31,7 +31,7 @@ #include "gpgsm.h" #include "../kbx/keybox.h" #include "keydb.h" -#include "i18n.h" +#include "../common/i18n.h" static int active_handles; diff --git a/sm/keylist.c b/sm/keylist.c index 6db42e3..1b1a261 100644 --- a/sm/keylist.c +++ b/sm/keylist.c @@ -34,8 +34,8 @@ #include "keydb.h" #include "../kbx/keybox.h" /* for KEYBOX_FLAG_* */ -#include "i18n.h" -#include "tlv.h" +#include "../common/i18n.h" +#include "../common/tlv.h" struct list_external_parm_s { @@ -346,6 +346,14 @@ email_kludge (const char *name) } +/* Print the compliance flags to field 18. ALGO is the gcrypt algo + * number. NBITS is the length of the key in bits. */ +static void +print_compliance_flags (int algo, unsigned int nbits, estream_t fp) +{ + if (algo == GCRY_PK_RSA && nbits >= 2048) + es_fputs ("23", fp); +} /* List one certificate in colon mode */ @@ -496,6 +504,8 @@ list_cert_colon (ctrl_t ctrl, ksba_cert_t cert, unsigned int validity, print_capabilities (cert, fp); /* Field 13, not used: */ es_putc (':', fp); + /* Field 14, not used: */ + es_putc (':', fp); if (have_secret || ctrl->with_secret) { char *cardsn; @@ -504,18 +514,20 @@ list_cert_colon (ctrl_t ctrl, ksba_cert_t cert, unsigned int validity, if (!gpgsm_agent_keyinfo (ctrl, p, &cardsn) && (cardsn || ctrl->with_secret)) { - /* Field 14, not used: */ - es_putc (':', fp); /* Field 15: Token serial number or secret key indicator. */ if (cardsn) es_fputs (cardsn, fp); else if (ctrl->with_secret) es_putc ('+', fp); - es_putc (':', fp); } xfree (cardsn); xfree (p); } + es_putc (':', fp); /* End of field 15. */ + es_putc (':', fp); /* End of field 16. */ + es_putc (':', fp); /* End of field 17. */ + print_compliance_flags (algo, nbits, fp); + es_putc (':', fp); /* End of field 18. */ es_putc ('\n', fp); /* FPR record */ @@ -29,8 +29,8 @@ #endif #include "gpgsm.h" -#include "i18n.h" -#include "sysutils.h" +#include "../common/i18n.h" +#include "../common/sysutils.h" #include "../common/tlv.h" #include "../common/sexp-parse.h" diff --git a/sm/qualified.c b/sm/qualified.c index 61b071c..718141e 100644 --- a/sm/qualified.c +++ b/sm/qualified.c @@ -26,7 +26,7 @@ #include <errno.h> #include "gpgsm.h" -#include "i18n.h" +#include "../common/i18n.h" #include <ksba.h> diff --git a/sm/server.c b/sm/server.c index 0fadcad..37d66e2 100644 --- a/sm/server.c +++ b/sm/server.c @@ -29,8 +29,8 @@ #include "gpgsm.h" #include <assuan.h> -#include "sysutils.h" -#include "server-help.h" +#include "../common/sysutils.h" +#include "../common/server-help.h" #define set_error(e,t) assuan_set_error (ctx, gpg_error (e), (t)) @@ -32,7 +32,7 @@ #include <ksba.h> #include "keydb.h" -#include "i18n.h" +#include "../common/i18n.h" /* Hash the data and return if something was hashed. Return -1 on error. */ diff --git a/sm/verify.c b/sm/verify.c index 1ac97cb..6c034e6 100644 --- a/sm/verify.c +++ b/sm/verify.c @@ -32,7 +32,7 @@ #include <ksba.h> #include "keydb.h" -#include "i18n.h" +#include "../common/i18n.h" static char * strtimestamp_r (ksba_isotime_t atime) |