diff options
| author | Werner Koch <[email protected]> | 2004-05-11 15:36:48 +0000 |
|---|---|---|
| committer | Werner Koch <[email protected]> | 2004-05-11 15:36:48 +0000 |
| commit | fdb1933917f9257b911c7e54ad046772c7ab4507 (patch) | |
| tree | d5eff2339fd602fb48244b0cf988427efabd8eab /sm/sign.c | |
| parent | * sysutils.c (disable_core_dumps): Only set the current limit. (diff) | |
| download | gnupg-fdb1933917f9257b911c7e54ad046772c7ab4507.tar.gz gnupg-fdb1933917f9257b911c7e54ad046772c7ab4507.zip | |
* sign.c (gpgsm_sign): Include the error source in the final error
message.
* decrypt.c (gpgsm_decrypt): Ditto.
* fingerprint.c (gpgsm_get_key_algo_info): New.
* sign.c (gpgsm_sign): Don't assume RSA in the status line.
* keylist.c (list_cert_colon): Really print the algorithm and key
length.
(list_cert_raw, list_cert_std): Ditto.
* gpgsm.h (opt): Add member CONFIG_FILENAME.
* gpgsm.c (main): Use it here instead of the local var.
Diffstat (limited to 'sm/sign.c')
| -rw-r--r-- | sm/sign.c | 18 |
1 files changed, 11 insertions, 7 deletions
@@ -616,12 +616,15 @@ gpgsm_sign (CTRL ctrl, CERTLIST signerlist, gcry_md_close (md); goto leave; } - rc = asprintf (&buf, "%c %d %d 00 %s %s", - detached? 'D':'S', - GCRY_PK_RSA, /* FIXME: get pk algo from cert */ - algo, - signed_at, - fpr); + { + int pkalgo = gpgsm_get_key_algo_info (cl->cert, NULL); + rc = asprintf (&buf, "%c %d %d 00 %s %s", + detached? 'D':'S', + pkalgo, + algo, + signed_at, + fpr); + } xfree (fpr); if (rc < 0) { @@ -651,7 +654,8 @@ gpgsm_sign (CTRL ctrl, CERTLIST signerlist, leave: if (rc) - log_error ("error creating signature: %s\n", gpg_strerror (rc)); + log_error ("error creating signature: %s <%s>\n", + gpg_strerror (rc), gpg_strsource (rc) ); if (release_signerlist) gpgsm_release_certlist (signerlist); ksba_cms_release (cms); |
