[git] GnuPG - branch, master, updated. gnupg-2.1.0-beta783-12-gcb680c5
by Werner Koch
cvs at cvs.gnupg.org
Wed Aug 20 11:58:21 CEST 2014
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The GNU Privacy Guard".
The branch, master has been updated
via cb680c5ea540738692a5c74951802b0fdc658e85 (commit)
from 31649e72fd106a990614ce3cf720640a841ba722 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit cb680c5ea540738692a5c74951802b0fdc658e85
Author: Werner Koch <wk at gnupg.org>
Date: Wed Aug 20 09:59:36 2014 +0200
gpg: Fix "can't handle public key algorithm" warning.
* g10/parse-packet.c (unknown_pubkey_warning): Check for encr/sign
capabilities.
diff --git a/g10/parse-packet.c b/g10/parse-packet.c
index c69393a..cfae788 100644
--- a/g10/parse-packet.c
+++ b/g10/parse-packet.c
@@ -195,12 +195,29 @@ unknown_pubkey_warning (int algo)
{
static byte unknown_pubkey_algos[256];
- algo &= 0xff;
- if (!unknown_pubkey_algos[algo])
+ /* First check whether the algorithm is usable but not suitable for
+ encryption/signing. */
+ if (pubkey_get_npkey (algo))
{
if (opt.verbose)
- log_info (_("can't handle public key algorithm %d\n"), algo);
- unknown_pubkey_algos[algo] = 1;
+ {
+ if (!pubkey_get_nsig (algo))
+ log_info ("public key algorithm %s not suitable for %s\n",
+ openpgp_pk_algo_name (algo), "signing");
+ if (!pubkey_get_nenc (algo))
+ log_info ("public key algorithm %s not suitable for %s\n",
+ openpgp_pk_algo_name (algo), "encryption");
+ }
+ }
+ else
+ {
+ algo &= 0xff;
+ if (!unknown_pubkey_algos[algo])
+ {
+ if (opt.verbose)
+ log_info (_("can't handle public key algorithm %d\n"), algo);
+ unknown_pubkey_algos[algo] = 1;
+ }
}
}
-----------------------------------------------------------------------
Summary of changes:
g10/parse-packet.c | 25 +++++++++++++++++++++----
1 file changed, 21 insertions(+), 4 deletions(-)
hooks/post-receive
--
The GNU Privacy Guard
http://git.gnupg.org
More information about the Gnupg-commits
mailing list