From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Sascha Wilde Newsgroups: gmane.emacs.devel Subject: Re: Fix needed for communication with gpg-agent Date: Fri, 23 Feb 2007 11:27:38 +0100 Message-ID: References: <87irdzs6pp.fsf@stupidchicken.com> <87fy91g1pl.fsf@catnip.gol.com> <87wt2dk2rv.fsf@stupidchicken.com> <873b4yt7xx.fsf@stupidchicken.com> <87ps82ukz8.fsf@wheatstone.g10code.de> <87slcynii0.fsf@stupidchicken.com> <87ps81tfuy.fsf@wheatstone.g10code.de> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Trace: sea.gmane.org 1172226495 6482 80.91.229.12 (23 Feb 2007 10:28:15 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 23 Feb 2007 10:28:15 +0000 (UTC) Cc: Daiki Ueno , emacs-devel@gnu.org, rms@gnu.org, Miles Bader To: Chong Yidong Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Feb 23 11:28:05 2007 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 1HKXem-0002OD-BS for ged-emacs-devel@m.gmane.org; Fri, 23 Feb 2007 11:28:04 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HKXel-0002RU-LH for ged-emacs-devel@m.gmane.org; Fri, 23 Feb 2007 05:28:03 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HKXeW-0002RK-Oy for emacs-devel@gnu.org; Fri, 23 Feb 2007 05:27:48 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HKXeT-0002R0-BS for emacs-devel@gnu.org; Fri, 23 Feb 2007 05:27:46 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HKXeS-0002Qx-Rf for emacs-devel@gnu.org; Fri, 23 Feb 2007 05:27:45 -0500 Original-Received: from ns.km1136.keymachine.de ([62.141.58.119] helo=km1136.keymachine.de) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1HKXeQ-0002HT-Rm; Fri, 23 Feb 2007 05:27:43 -0500 Original-Received: from kenny.sha-bang.de (xdsld234.osnanet.de [212.95.103.234]) (authenticated bits=0) by km1136.keymachine.de (8.12.11.20060308/8.12.10) with ESMTP id l1NARbjA030733; Fri, 23 Feb 2007 11:27:37 +0100 Original-Received: from wilde by kenny.sha-bang.de with local (Kenny MUA v.0409034.42) ID 1HKXeM-0000RM-5U; Fri, 23 Feb 2007 11:27:38 +0100 In-Reply-To: <87ps81tfuy.fsf@wheatstone.g10code.de> (Werner Koch's message of "Fri\, 23 Feb 2007 09\:53\:09 +0100") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.93 (gnu/linux) X-detected-kernel: Linux 2.4-2.6 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:66662 Archived-At: Werner Koch wrote: > On Thu, 22 Feb 2007 19:40, cyd@stupidchicken.com said: >> > Is it possible to enhance server-start/emacsclient so that it does not >> > edit a file but asks for string and returns that one? Pinentry could >> > then use this feature for user interaction. >> >> I'm not sure how this suggestion could work. > > Recall that pinentry is called on the sole discretion of gpg-agent. > Only gpg-agent knows whether Pinentry needs to be called. > > My suggestion is this: > > +-------+ +-----------+ +-----------+ +----------+ > | emacs | -> | gpg/gpgsm | -> | gpg-agent | ----> | pinentry | > +-------+ +-----------+ +-----------+ (may) +----------+ > ^ | > | | > +--------------------------------------------------+ > (some mechanism to loop back to emacs) > > Pinentry uses this: > > if DISPLAY set > Use GUI mode; no problem > else if SOME_EMACS_ENVVAR set > Loop back to emacs > else=20 > Use Curses This looks very good to me, BUT: this would need a new (extended) version of pinentry, which will probably not be available in most major distributions for the near future, so I don't think this would be a feasible solution for the 22 release. > to decide wether that emacs loop back method is to be used. It will > then ask emacs: Please create a form or a minibuffer with this or that > description and return the user input to me. > > I don't know the emacsclient protocol and whether it can easiliy be > enhanced for that case. I don't know that either, but we could always create a dedicated socket for such an service, so yes, I think this would be the right thing to do -- after the release. cheers sascha --=20 Sascha Wilde Nota bene: wenn Word f=FCr L=E4ngeres geeignet w=E4re, w=FCrde es schlie=DF= lich nicht Word, sondern Sentence, Page oder Article hei=DFen -- Matthias M=FChlich in dctt