[svn] GnuPG - r4648 - branches/STABLE-BRANCH-1-4/g10
svn author wk
cvs at cvs.gnupg.org
Tue Dec 11 14:21:33 CET 2007
Author: wk
Date: 2007-12-11 14:21:30 +0100 (Tue, 11 Dec 2007)
New Revision: 4648
Modified:
branches/STABLE-BRANCH-1-4/g10/ChangeLog
branches/STABLE-BRANCH-1-4/g10/mainproc.c
Log:
Allow decryption using type 20 Elgamal keys.
Modified: branches/STABLE-BRANCH-1-4/g10/ChangeLog
===================================================================
--- branches/STABLE-BRANCH-1-4/g10/ChangeLog 2007-12-11 13:19:38 UTC (rev 4647)
+++ branches/STABLE-BRANCH-1-4/g10/ChangeLog 2007-12-11 13:21:30 UTC (rev 4648)
@@ -1,3 +1,8 @@
+2007-12-11 Werner Koch <wk at g10code.com>
+
+ * mainproc.c (proc_pubkey_enc): Allow type 20 Elgamal key for
+ decryption.
+
2007-12-10 Werner Koch <wk at g10code.com>
* cardglue.h (gpg_error_from_syserror): New.
Modified: branches/STABLE-BRANCH-1-4/g10/mainproc.c
===================================================================
--- branches/STABLE-BRANCH-1-4/g10/mainproc.c 2007-12-11 13:19:38 UTC (rev 4647)
+++ branches/STABLE-BRANCH-1-4/g10/mainproc.c 2007-12-11 13:21:30 UTC (rev 4648)
@@ -402,10 +402,17 @@
}
}
else if( is_ELGAMAL(enc->pubkey_algo)
- || enc->pubkey_algo == PUBKEY_ALGO_DSA
- || is_RSA(enc->pubkey_algo) ) {
- /* FIXME: strore this all in a list and process it later */
+ || enc->pubkey_algo == PUBKEY_ALGO_DSA
+ || is_RSA(enc->pubkey_algo)
+ || enc->pubkey_algo == PUBKEY_ALGO_ELGAMAL) {
+ /* Note that we also allow type 20 Elgamal keys for decryption.
+ There are still a couple of those keys in active use as a
+ subkey. */
+ /* FIXME: Store this all in a list and process it later so that
+ we can prioritize what key to use. This gives a better user
+ experience if wildcard keyids are used. */
+
if ( !c->dek && ((!enc->keyid[0] && !enc->keyid[1])
|| opt.try_all_secrets
|| !seckey_available( enc->keyid )) ) {
More information about the Gnupg-commits
mailing list