From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ted Zlatanov Newsgroups: gmane.emacs.devel Subject: Re: EasyPG API and usage questions Date: Wed, 05 Mar 2008 10:41:06 -0600 Organization: =?utf-8?B?0KLQtdC+0LTQvtGAINCX0LvQsNGC0LDQvdC+0LI=?= @ Cienfuegos Message-ID: <86fxv586ot.fsf@lifelogs.com> References: <87d4qiaj3j.fsf@broken.deisui.org> <87skzdi3pw.fsf@bzg.ath.cx> <871w6w1k38.fsf@broken.deisui.org> <8663w7hg1o.fsf_-_@lifelogs.com> <54a15d860802291623m3c9844d1k80515e661f435179@mail.gmail.com> <86bq5vd0gk.fsf@lifelogs.com> <87wsojngp6.fsf@broken.deisui.org> <867igiblec.fsf@jumptrading.com> <87d4q9my3h.fsf@broken.deisui.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1204735283 28028 80.91.229.12 (5 Mar 2008 16:41:23 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 5 Mar 2008 16:41:23 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed Mar 05 17:41:46 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JWwfJ-00021J-Dp for ged-emacs-devel@m.gmane.org; Wed, 05 Mar 2008 17:40:25 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JWwel-00041f-U2 for ged-emacs-devel@m.gmane.org; Wed, 05 Mar 2008 11:39:51 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JWweA-0003hq-LU for emacs-devel@gnu.org; Wed, 05 Mar 2008 11:39:14 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JWwe4-0003fr-UT for emacs-devel@gnu.org; Wed, 05 Mar 2008 11:39:13 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JWwe4-0003fo-JZ for emacs-devel@gnu.org; Wed, 05 Mar 2008 11:39:08 -0500 Original-Received: from main.gmane.org ([80.91.229.2] helo=ciao.gmane.org) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1JWwe4-0001Ug-5d for emacs-devel@gnu.org; Wed, 05 Mar 2008 11:39:08 -0500 Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1JWwdw-0007za-Er for emacs-devel@gnu.org; Wed, 05 Mar 2008 16:39:00 +0000 Original-Received: from 38.98.147.130 ([38.98.147.130]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 05 Mar 2008 16:39:00 +0000 Original-Received: from tzz by 38.98.147.130 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 05 Mar 2008 16:39:00 +0000 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 58 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: 38.98.147.130 X-Face: bd.DQ~'29fIs`T_%O%C\g%6jW)yi[zuz6; d4V0`@y-~$#3P_Ng{@m+e4o<4P'#(_GJQ%TT= D}[Ep*b!\e,fBZ'j_+#"Ps?s2!4H2-Y"sx" User-Agent: Gnus/5.110007 (No Gnus v0.7) Emacs/23.0.60 (gnu/linux) Cancel-Lock: sha1:UdU3xsMBBgbkkwDwAX0h36sjsco= X-detected-kernel: by monty-python.gnu.org: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:91396 Archived-At: On Wed, 05 Mar 2008 16:25:22 +0900 Daiki Ueno wrote: DU> Ah, that's a bug. Thanks for finding it in the corner case. Here is a DU> patch to fix this. DU> Index: lisp/epa.el DU> =================================================================== DU> RCS file: /sources/emacs/emacs/lisp/epa.el,v DU> retrieving revision 1.6 DU> diff -c -r1.6 epa.el DU> *** lisp/epa.el 12 Feb 2008 01:24:20 -0000 1.6 DU> --- lisp/epa.el 5 Mar 2008 07:16:21 -0000 DU> *************** DU> *** 542,551 **** DU> NAMES is a list of strings to be matched with keys. If it is nil, all DU> the keys are listed. DU> If SECRET is non-nil, list secret keys instead of public keys." DU> ! (let ((keys (epg-list-keys context names secret))) DU> ! (if (> (length keys) 1) DU> ! (epa--select-keys prompt keys) DU> ! keys))) DU> (defun epa--show-key (key) DU> (let* ((primary-sub-key (car (epg-key-sub-key-list key))) DU> --- 542,548 ---- DU> NAMES is a list of strings to be matched with keys. If it is nil, all DU> the keys are listed. DU> If SECRET is non-nil, list secret keys instead of public keys." DU> ! (epa--select-keys prompt (epg-list-keys context names secret))) DU> (defun epa--show-key (key) DU> (let* ((primary-sub-key (car (epg-key-sub-key-list key))) I can confirm this fixes the bug, I hope you can commit it soon. It's very nice that if I cancel the encryption, I remain in the file.gpg buffer, but it's unsaved. If I try to save again, it brings up the save dialog again. If I open a symetrically encrypted file.gpg and write it to another file1.gpg, I never get a question about the encryption. EasyPG assumes I want symmetric encryption again. I don't know if that's a feature or a bug. Can the passphrase and symmetric encryption/key choice be automatically cached for a whole directory of files, if it's entered for any one of them? That way I can have ~/Maildir-crypt/{cur,tmp,new} encrypted consistently, for example. In the key selection buffer, (described as "Major mode for `epa-list-keys'") I think it would be nice to have C-c C-c and Enter anywhere (except the "Cancel" button or on a key) equivalent to "OK" C-c C-k equivalent to "Cancel" Thanks Ted