* bug#2412: spurious "Sign failed" errors
@ 2009-02-20 18:03 Sven Joachim
0 siblings, 0 replies; 7+ messages in thread
From: Sven Joachim @ 2009-02-20 18:03 UTC (permalink / raw)
[-- Attachment #2: Type: text/plain, Size: 1290 bytes --]
Gnus v5.13
GNU Emacs 23.0.60.1 (i486-pc-linux-gnu, GTK+ Version 2.12.11)
of 2008-11-30 on turtle, modified by Debian
200 news.motzarella.org InterNetNews NNRP server INN 2.4.5 ready (posting ok).
I'm experiencing painful, but not always reproducible problems with
sending or previewing signed mails. Often I get an error "Sign failed"
and a backtrace like this:
,----
| Debugger entered--Lisp error: (error "Sign failed")
| signal(error ("Sign failed"))
| byte-code("<snipped>" [mml2015-epg-secret-key-id-list error password-cache-remove signal] 4)
| mml2015-epg-sign((part (sign . "pgpmime") (tag-location . 186) (contents . "Nur ein Test.\n")))
| mml2015-sign((part (sign . "pgpmime") (tag-location . 186) (contents . "Nur ein Test.\n")))
| mml-pgpmime-sign-buffer((part (sign . "pgpmime") (tag-location . 186) (contents . "Nur ein Test.\n")))
| mml-generate-mime-1((part (sign . "pgpmime") (tag-location . 186) (contents . "Nur ein Test.\n")))
| mml-generate-mime()
| message-encode-message-body()
| mml-to-mime()
| mml-preview(nil)
| call-interactively(mml-preview nil nil)
`----
If this happens during sending, the message actually is signed and sent,
but no copy lands in my archive folder. :-(
I'm using gpg-agent with pinentry-gtk2 for the passphrase.
[-- Attachment #3: User settings --]
[-- Type: application/emacs-lisp, Size: 3572 bytes --]
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#2412: spurious "Sign failed" errors
@ 2009-02-21 17:25 Chong Yidong
2009-02-21 20:40 ` Daiki Ueno
0 siblings, 1 reply; 7+ messages in thread
From: Chong Yidong @ 2009-02-21 17:25 UTC (permalink / raw)
To: Daiki Ueno; +Cc: 2412, Sven Joachim
Hi Daiki,
This may be a bug in epg, could you take a look? This is Bug#2412 in
the Emacs bug tracker. Thanks.
Sven Joachim <svenjoac@gmx.de> wrote:
> Gnus v5.13
> GNU Emacs 23.0.60.1 (i486-pc-linux-gnu, GTK+ Version 2.12.11)
> of 2008-11-30 on turtle, modified by Debian
> 200 news.motzarella.org InterNetNews NNRP server INN 2.4.5 ready
> (posting ok).
> I'm experiencing painful, but not always reproducible problems with
> sending or previewing signed mails. Often I get an error "Sign failed"
> and a backtrace like this:
> ,----
> | Debugger entered--Lisp error: (error "Sign failed")
> | signal(error ("Sign failed"))
> | byte-code("<snipped>" [mml2015-epg-secret-key-id-list error password-cache-remove signal] 4)
> | mml2015-epg-sign((part (sign . "pgpmime") (tag-location . 186) (contents . "Nur ein Test.\n")))
> | mml2015-sign((part (sign . "pgpmime") (tag-location . 186) (contents . "Nur ein Test.\n")))
> | mml-pgpmime-sign-buffer((part (sign . "pgpmime") (tag-location . 186) (contents . "Nur ein Test.\n")))
> | mml-generate-mime-1((part (sign . "pgpmime") (tag-location . 186) (contents . "Nur ein Test.\n")))
> | mml-generate-mime()
> | message-encode-message-body()
> | mml-to-mime()
> | mml-preview(nil)
> | call-interactively(mml-preview nil nil)
> `----
>
> If this happens during sending, the message actually is signed and sent,
> but no copy lands in my archive folder. :-(
>
> I'm using gpg-agent with pinentry-gtk2 for the passphrase.
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#2412: spurious "Sign failed" errors
2009-02-21 17:25 Chong Yidong
@ 2009-02-21 20:40 ` Daiki Ueno
0 siblings, 0 replies; 7+ messages in thread
From: Daiki Ueno @ 2009-02-21 20:40 UTC (permalink / raw)
To: Chong Yidong; +Cc: 2412, Sven Joachim
Chong Yidong <cyd@stupidchicken.com> writes:
> Hi Daiki,
>
> This may be a bug in epg, could you take a look? This is Bug#2412 in
> the Emacs bug tracker. Thanks.
Thanks for noticing this.
> Sven Joachim <svenjoac@gmx.de> wrote:
>> | Debugger entered--Lisp error: (error "Sign failed")
>> | signal(error ("Sign failed"))
>> | byte-code("<snipped>" [mml2015-epg-secret-key-id-list error password-cache-remove signal] 4)
>> | mml2015-epg-sign((part (sign . "pgpmime") (tag-location . 186) (contents . "Nur ein Test.\n")))
It looks like epg is signalling the error.
Sven, could you please try (setq epg-debug t) and show me the contents
of " *epg-debug*" buffer next time you see the error?
Regards,
--
Daiki Ueno
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#2412: spurious "Sign failed" errors
@ 2009-04-16 4:27 Chong Yidong
2009-04-16 18:56 ` Sven Joachim
0 siblings, 1 reply; 7+ messages in thread
From: Chong Yidong @ 2009-04-16 4:27 UTC (permalink / raw)
To: Sven Joachim; +Cc: 2412
Hi Sven,
Are you still experiencing these problems? If so, please do as Daiki
requested:
> could you please try (setq epg-debug t) and show me the contents of
> " *epg-debug*" buffer next time you see the error?
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#2412: spurious "Sign failed" errors
2009-04-16 4:27 bug#2412: spurious "Sign failed" errors Chong Yidong
@ 2009-04-16 18:56 ` Sven Joachim
2009-05-03 5:43 ` Daiki Ueno
0 siblings, 1 reply; 7+ messages in thread
From: Sven Joachim @ 2009-04-16 18:56 UTC (permalink / raw)
To: Chong Yidong; +Cc: Daiki Ueno, 2412
On 2009-04-16 06:27 +0200, Chong Yidong wrote:
> Hi Sven,
>
> Are you still experiencing these problems?
Sorry for not replying sooner. Yes, they still persist. :-(
> If so, please do as Daiki requested:
>
>> could you please try (setq epg-debug t) and show me the contents of
>> " *epg-debug*" buffer next time you see the error?
Looks innocent enough to me:
,----
| gpg --no-tty --status-fd 1 --yes --use-agent --command-fd 0 --armor --textmode --output /tmp/epg-output2077H-b --detach-sign
| [GNUPG:] USERID_HINT ECB679C787E9AABE Sven Joachim (Debian User) <svenjoac@gmx.de>
| [GNUPG:] NEED_PASSPHRASE ECB679C787E9AABE ECB679C787E9AABE 17 0
| [GNUPG:] GOOD_PASSPHRASE
| [GNUPG:] BEGIN_SIGNING
| [GNUPG:] SIG_CREATED D 17 2 01 1239906974 9AACBC0C69283380715D3788ECB679C787E9AABE
| gpg --no-tty --status-fd 1 --yes --use-agent --command-fd 0 --armor --textmode --output /tmp/epg-output2077UIi --detach-sign
| [GNUPG:] USERID_HINT ECB679C787E9AABE Sven Joachim (Debian User) <svenjoac@gmx.de>
| [GNUPG:] NEED_PASSPHRASE ECB679C787E9AABE ECB679C787E9AABE 17 0
| [GNUPG:] GOOD_PASSPHRASE
| [GNUPG:] BEGIN_SIGNING
| [GNUPG:] SIG_CREATED D 17 2 01 1239906984 9AACBC0C69283380715D3788ECB679C787E9AABE
`----
IIRC, the first try did show the preview of the test mail, the second
one gave the "Sign failed" error.
Sven
^ permalink raw reply [flat|nested] 7+ messages in thread
* bug#2412: spurious "Sign failed" errors
2009-04-16 18:56 ` Sven Joachim
@ 2009-05-03 5:43 ` Daiki Ueno
2009-05-03 10:33 ` Sven Joachim
0 siblings, 1 reply; 7+ messages in thread
From: Daiki Ueno @ 2009-05-03 5:43 UTC (permalink / raw)
To: Sven Joachim; +Cc: Chong Yidong, 2412
[-- Attachment #1: Type: text/plain, Size: 508 bytes --]
Hi,
Sven Joachim <svenjoac@gmx.de> writes:
>>> could you please try (setq epg-debug t) and show me the contents of
>>> " *epg-debug*" buffer next time you see the error?
> Looks innocent enough to me:
> | [GNUPG:] SIG_CREATED D 17 2 01 1239906974 9AACBC0C69283380715D3788ECB679C787E9AABE
> | [GNUPG:] SIG_CREATED D 17 2 01 1239906984 9AACBC0C69283380715D3788ECB679C787E9AABE
Thanks. It looks innocent for me too, but now I can suspect a timing
problem. Could you please try the patch attached below?
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: epg.el.diff --]
[-- Type: text/x-diff, Size: 533 bytes --]
diff --git a/lisp/epg.el b/lisp/epg.el
index e96258f..3c80ef9 100644
--- a/lisp/epg.el
+++ b/lisp/epg.el
@@ -1175,7 +1175,8 @@ This function is for internal use only."
(defun epg-wait-for-completion (context)
"Wait until the `epg-gpg-program' process completes."
(while (eq (process-status (epg-context-process context)) 'run)
- (accept-process-output (epg-context-process context) 1)))
+ (accept-process-output (epg-context-process context) 1))
+ (sleep-for 0.1))
(defun epg-reset (context)
"Reset the CONTEXT."
[-- Attachment #3: Type: text/plain, Size: 25 bytes --]
Regards,
--
Daiki Ueno
^ permalink raw reply related [flat|nested] 7+ messages in thread
* bug#2412: spurious "Sign failed" errors
2009-05-03 5:43 ` Daiki Ueno
@ 2009-05-03 10:33 ` Sven Joachim
0 siblings, 0 replies; 7+ messages in thread
From: Sven Joachim @ 2009-05-03 10:33 UTC (permalink / raw)
To: Daiki Ueno; +Cc: Chong Yidong, 2412
On 2009-05-03 07:43 +0200, Daiki Ueno wrote:
> Sven Joachim <svenjoac@gmx.de> writes:
>
>>>> could you please try (setq epg-debug t) and show me the contents of
>>>> " *epg-debug*" buffer next time you see the error?
>
>> Looks innocent enough to me:
>
>> | [GNUPG:] SIG_CREATED D 17 2 01 1239906974 9AACBC0C69283380715D3788ECB679C787E9AABE
>> | [GNUPG:] SIG_CREATED D 17 2 01 1239906984 9AACBC0C69283380715D3788ECB679C787E9AABE
>
> Thanks. It looks innocent for me too, but now I can suspect a timing
> problem. Could you please try the patch attached below?
>
>
> diff --git a/lisp/epg.el b/lisp/epg.el
> index e96258f..3c80ef9 100644
> --- a/lisp/epg.el
> +++ b/lisp/epg.el
> @@ -1175,7 +1175,8 @@ This function is for internal use only."
> (defun epg-wait-for-completion (context)
> "Wait until the `epg-gpg-program' process completes."
> (while (eq (process-status (epg-context-process context)) 'run)
> - (accept-process-output (epg-context-process context) 1)))
> + (accept-process-output (epg-context-process context) 1))
> + (sleep-for 0.1))
>
> (defun epg-reset (context)
> "Reset the CONTEXT."
That seems to do the trick. At least, I had no problem in ~15 attempts
to preview/send signed messages, whereas without your patch the "Sign
failed" error would happen about every second time.
Cheers,
Sven
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2009-05-03 10:33 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-04-16 4:27 bug#2412: spurious "Sign failed" errors Chong Yidong
2009-04-16 18:56 ` Sven Joachim
2009-05-03 5:43 ` Daiki Ueno
2009-05-03 10:33 ` Sven Joachim
-- strict thread matches above, loose matches on Subject: below --
2009-02-21 17:25 Chong Yidong
2009-02-21 20:40 ` Daiki Ueno
2009-02-20 18:03 Sven Joachim
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).