From: Lars Ingebrigtsen <larsi@gnus.org>
To: Arne Babenhauserheide <arne_bab@web.de>
Cc: 39058@debbugs.gnu.org
Subject: bug#39058: 26.1; epg-sign-string should report an error if no pinentry is available
Date: Sun, 02 Aug 2020 10:49:16 +0200 [thread overview]
Message-ID: <87v9i1l9f7.fsf@gnus.org> (raw)
In-Reply-To: <87h814nwkd.fsf@web.de> (Arne Babenhauserheide's message of "Thu, 09 Jan 2020 22:34:26 +0100")
Arne Babenhauserheide <arne_bab@web.de> writes:
> If you run epg-sign-string without having pinentry available, then the
> result is nil and instead of an error, even though the status-code seen
> for the process returned by epg-start-sign is 2 and the content of the
> process-buffer is
>
> "
> Process epg exited abnormally with code 2
> [GNUPG:] KEY_CONSIDERED XXXXXXXXXXXXXXX… 2
> [GNUPG:] BEGIN_SIGNING H8
> [GNUPG:] FAILURE sign 67108949
> "
>
> And the buffer *epg-error*-270683 contains:
> gpg: Beglaubigung fehlgeschlagen: Kein Pinentry
> gpg: signing failed: Kein Pinentry
When you say "without having pinentry available", do you mean that you
click "cancel" in the pinentry window, or that there's no pinentry
available at all?
> To test:
>
> (setq context (epg-make-context 'OpenPGP))
> (setq epg-test-proc (epg-start-sign context (epg-make-data-from-string
> "foo") t))
> (let ((print-length nil) (print-level nil))
> (print context))
> (epg-context-result-for context 'sign)
> (print (epg-context-result-for context 'error))
> (with-current-buffer (process-buffer epg-test-proc) (buffer-string))
> (print (epg-context-result-for context 'error)
> ;; prints \nnilnil
I'm able to reproduce this when clicking "cancel" in the pinentry
window -- no error is signalled anywhere, which I think it should be.
I'll try to look into that.
> This currently breaks signing emails for me.
I don't quite get why it breaks signing emails...
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
next prev parent reply other threads:[~2020-08-02 8:49 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-01-09 21:34 bug#39058: 26.1; epg-sign-string should report an error if no pinentry is available Arne Babenhauserheide
2020-08-02 8:49 ` Lars Ingebrigtsen [this message]
2020-08-02 9:29 ` Lars Ingebrigtsen
2020-08-02 9:33 ` Lars Ingebrigtsen
2020-10-26 15:47 ` Lars Ingebrigtsen
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://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87v9i1l9f7.fsf@gnus.org \
--to=larsi@gnus.org \
--cc=39058@debbugs.gnu.org \
--cc=arne_bab@web.de \
/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://git.savannah.gnu.org/cgit/emacs.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).