unofficial mirror of notmuch@notmuchmail.org
 help / color / mirror / code / Atom feed
From: David Bremner <david@tethera.net>
To: Jameson Graef Rollins <jrollins@finestructure.net>,
	Jani Nikula <jani@nikula.org>,
	notmuch@notmuchmail.org
Subject: Re: [PATCH] cli: crypto: tell gmime to use gpg-agent
Date: Wed, 27 Feb 2013 13:11:48 -0400	[thread overview]
Message-ID: <87r4k1znor.fsf@maritornes.cs.unb.ca> (raw)
In-Reply-To: <87hakxpwcu.fsf@servo.finestructure.net>

Jameson Graef Rollins <jrollins@finestructure.net> writes:

> I will argue that the "use-agent" option should be enabled.  If we force
> use of gpg-agent, then we don't allow people to opt out of using it.
> That's not very user friendly, particularly if someone has not enabled
> it for a specific reason.

But right now we force people to enable the agent globally via use-agent
if they want to decrypt mail in notmuch-cli/emacs. The proposed change
allows them to use the agent only for notmuch.

> But I think more to the point we need a little bit of due diligence of
> the effects of this before we enable it.  What happens if gpg-agent is
> not available?  What happens if there is no X session?  Tests that probe
> the various circumstances would be useful.

I don't think we should directly care about the presence of an X session
or not; the agent protocol doesn't depend on how the agent was started
afaik. 

> I do note, though, that the error messages are not very useful.  It
> would be nice if could figure out that the decryption failed because of
> lack of agent and inform the user of that.

Yes, it would be nice to detect a missing/non-responsive agent. And that
could be used by tests.

> We should probably also update the show man page to make explicit that
> an agent may be required.

We probably need to word it more strongly than that.  If the user wants
decryption then notmuch requires an agent; if they want encryption or
signing then message-mode (really probably easypg) requires an agent.
I'm not sure how it manages it, but according to Jani's experiments it
seems that message mode already uses the agent independently of the
user's config; perhaps via the '--use-agent' argument to gpg.  So the
current situation is unfortunately asymmetric.

Of course it would help if there was documentation for the emacs
interface that we could update.

  reply	other threads:[~2013-02-27 17:11 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-02-27  7:40 [PATCH] cli: crypto: tell gmime to use gpg-agent Jani Nikula
2013-02-27  8:45 ` Tomi Ollila
2013-02-27 16:14 ` Jameson Graef Rollins
2013-02-27 17:11   ` David Bremner [this message]
2013-02-27 17:25     ` Jameson Graef Rollins
2013-02-27 22:46       ` Jani Nikula
2013-03-01  0:10         ` Jameson Graef Rollins
2013-03-01  6:12           ` Daniel Kahn Gillmor
2013-03-01  6:52             ` Tomi Ollila
2013-03-01 16:43 ` [PATCH] man: show and reply --decrypt option requires gpg-agent Jani Nikula
2013-03-01 16:56   ` Jameson Graef Rollins
2013-03-02 14:48 ` [PATCH] cli: crypto: tell gmime to use gpg-agent David Bremner

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://notmuchmail.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87r4k1znor.fsf@maritornes.cs.unb.ca \
    --to=david@tethera.net \
    --cc=jani@nikula.org \
    --cc=jrollins@finestructure.net \
    --cc=notmuch@notmuchmail.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://yhetil.org/notmuch.git/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).