Bug 316381 - Misleading error message when signing
Summary: Misleading error message when signing
Status: CONFIRMED
Alias: None
Product: kmail2
Classification: Applications
Component: crypto (show other bugs)
Version: 5.4.0
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-03-08 19:07 UTC by Rolf Eike Beer
Modified: 2017-01-14 15:19 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rolf Eike Beer 2013-03-08 19:07:21 UTC
There are basically 2 situations that lead to the same misleading error message:

-cancel the password entry (e.g. pinentry-qt) when asking for crypto password
-have the secret key unavailable when it should be read (by e.g. moving your secring.gpg out of the way) and click cancel instead of "send unsigned"

Both situations lead to an error message telling that there was an error during crypto operations. Since the operation was actively cancelled by the user no error message should be shown at all.

I.e.: handle "cancelled" different than "error".

Reproducible: Always
Comment 1 Laurent Montel 2015-03-27 10:09:23 UTC
Is it valid in last kdepim ?
I fixed canceled action in 4.14.x
Comment 2 Rolf Eike Beer 2015-03-27 11:23:49 UTC
> Is it valid in last kdepim ?
> I fixed canceled action in 4.14.x

I still see it in 4.14.6.
Comment 3 Laurent Montel 2015-03-27 12:46:46 UTC
Ok I will investigate it
Comment 4 Denis Kurz 2017-01-14 15:19:51 UTC
KMail now handles the two cases differently. However, the "error" message is still confusing. When clicking "Abort" in the password prompt, it says:

"Fehler beim Erstellen der Nachricht: Verarbeitung wurde abgebrochen"

which roughly translates to

"Error during message creation: Process was cancelled"

Sorry, I don't know the original english text.

Anyway, while a click on an "Abort" button might be an error from a programmer's point of view, it isn't an error from a user's point of view. Maybe it should say something like:

"Message signing was aborted. Your message has not been sent. If you want to send an unsigned message, please deselect the \"Sign\" option in the message composer."

In the other case (if the secring is not where it should be), it asks three times for my password, which of course even fails when I type the correct password. However, it then says "... Wrong passphrase." It shouldn't even ask three times, but give the correct message "I was unable to find your private key for signing. Please do this and that to fix the problem", I guess.