From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.emacs.gnus.general/82902 Path: news.gmane.org!not-for-mail From: =?utf-8?Q?=C5=81ukasz?= Stelmach Newsgroups: gmane.emacs.gnus.general Subject: Re: [BUG] mml2015-epg-find-usable-key finds unusable key Date: Sat, 16 Feb 2013 19:35:40 +0100 Message-ID: <87bobk85tv.fsf%stlman@poczta.fm> References: <87fw106la1.fsf%stlman@poczta.fm> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/signed; boundary="=-=-="; micalg=pgp-sha512; protocol="application/pgp-signature" X-Trace: ger.gmane.org 1361045722 8284 80.91.229.3 (16 Feb 2013 20:15:22 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 16 Feb 2013 20:15:22 +0000 (UTC) To: ding@gnus.org Original-X-From: ding-owner+M31168@lists.math.uh.edu Sat Feb 16 21:15:40 2013 Return-path: Envelope-to: ding-account@gmane.org Original-Received: from util0.math.uh.edu ([129.7.128.18]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1U6oAb-0003br-LD for ding-account@gmane.org; Sat, 16 Feb 2013 21:15:37 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.math.uh.edu) by util0.math.uh.edu with smtp (Exim 4.63) (envelope-from ) id 1U6o9d-0000qa-0y; Sat, 16 Feb 2013 14:14:37 -0600 Original-Received: from mx2.math.uh.edu ([129.7.128.33]) by util0.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.63) (envelope-from ) id 1U6mcX-0000RN-K7 for ding@lists.math.uh.edu; Sat, 16 Feb 2013 12:36:21 -0600 Original-Received: from quimby.gnus.org ([80.91.231.51]) by mx2.math.uh.edu with esmtps (TLSv1:AES256-SHA:256) (Exim 4.76) (envelope-from ) id 1U6mcT-0003xv-Eh for ding@lists.math.uh.edu; Sat, 16 Feb 2013 12:36:21 -0600 Original-Received: from plane.gmane.org ([80.91.229.3]) by quimby.gnus.org with esmtp (Exim 4.72) (envelope-from ) id 1U6mcS-0002xs-3I for ding@gnus.org; Sat, 16 Feb 2013 19:36:16 +0100 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1U6mcl-0001JW-Ak for ding@gnus.org; Sat, 16 Feb 2013 19:36:35 +0100 Original-Received: from p54af4923.dip0.t-ipconnect.de ([84.175.73.35]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 16 Feb 2013 19:36:35 +0100 Original-Received: from stlman by p54af4923.dip0.t-ipconnect.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 16 Feb 2013 19:36:35 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 77 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: p54af4923.dip0.t-ipconnect.de User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/23.2 (gnu/linux) Cancel-Lock: sha1:v0v6O9c5w9iqCNOULCYE868cyA0= X-Spam-Score: -1.9 (-) List-ID: Precedence: bulk Xref: news.gmane.org gmane.emacs.gnus.general:82902 Archived-At: --=-=-= Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Daiki Ueno writes: > =C5=81ukasz Stelmach writes: > >> It looks like there is a sort of bug in mml2015-epg-encrypt at line >> 1117. >> >> http://git.gnus.org/cgit/gnus.git/tree/lisp/mml2015.el?id=3D6e422932976e= 94d6dbb7ad602c5be3eb481fe46c#n1117) >> >> The whole form that begins at line 1113 converts list of recipients >> provided as email addresses, key IDs or anything gpg can digest into epg >> "objects". Unfortunately there is one corner case that makes this code >> fail. That is when a key is valid but a uid on it has been revoked. > > Thanks for the report. > >> epg.el is a part of emacs, mml2015.el belongs to gnus. IMHO it is >> mml2015-epg-find-usable-key that should be fixed. The function should >> accept and additional (optional?) parameter with a recipient uid as >> passed to epg-list-keys and reject keys with all uids matching the >> recipient parameter revoked. > > Sounds reasonable. I plan to apply the attached patch. The patch needed a fix: there was a space before tab and my name for the changelog has been messed up (maybe due to encoding issues?). See the first attachment. There are two more issues: 1. mml2015-find-usable-key is called from mml2015-epg-find-usable-secret-key. Your patch hasn't changed the invocation. See the second attachment. 2. IMHO mml2015-epg-check-user-id should return true if a key id is passed as a uid to check. I assume that if a caller passes id to mml2015-find-usable-key find See the third attachment. All atachments has been generated with git-format-patch and are ready to apply with git-am onto 98f5834. I've got some more patches for mml2015-epg-* but let's concentrate on the revoked uid handling. PS. It looks like this massage originally hasn't made it to the group (because of attachments?) =2D-=20 Mi=C5=82ego dnia, =C5=81ukasz Stelmach --=-=-= Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.17 (GNU/Linux) iQF8BAEBCgBmBQJRH9GRXxSAAAAAAC4AKGlzc3Vlci1mcHJAbm90YXRpb25zLm9w ZW5wZ3AuZmlmdGhob3JzZW1hbi5uZXQ5MEY5NEM3QTI4NzRFNDc2ODMwNEMxNEYw MEI2OTc2QzYzOTFEMzcxAAoJEAC2l2xjkdNxHLsIAJbAQj79RFLQus0ZZg+OczgJ ee9zsbSft0zQa78gB/Df5CSMGRou+0gVtyWZ7XA54nF9mi+CyX5xuplxj4SH7Zjg azY0UWwzvCsrjav82bBuQygwosOyF2kJGxw0vmCRiqDBnyfuMJpzBEiRxfpPoIi4 H3jDKoNeaCumt2NYWONHKmaEOhDxV1h8ezUzrr9KH6zf8qWb1ALvCxQQ23FS8FI9 +w75qA1mqH6Qyva6jdJthfIfNfmTcyzlDOTRMHrPhSZKeup9hfsBYiNNULP+W0Du Wu431glBnHL0lS30OlQO9t2PpUqMu2o0C3PhoPF6wWhcNx4EX4UoL8qis1Xz4Qc= =9nZ8 -----END PGP SIGNATURE----- --=-=-=--