Bug 321606 - Cannot sign messages
Summary: Cannot sign messages
Status: RESOLVED WORKSFORME
Alias: None
Product: kgpg
Classification: Applications
Component: general (show other bugs)
Version: 2.9.1
Platform: Ubuntu Linux
: NOR major
Target Milestone: ---
Assignee: Rolf Eike Beer
URL:
Keywords: triaged
Depends on:
Blocks:
 
Reported: 2013-06-25 17:23 UTC by Arthur Breitman
Modified: 2018-10-27 02:16 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Screenshot of steps on encrypt/decrypt vs sign. (278.87 KB, image/png)
2016-01-19 12:15 UTC, Dan Bărăgan
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Arthur Breitman 2013-06-25 17:23:12 UTC
(note, bugzilla doesn't let me enter the actual version number which is 2.9.1 and not 2.9.0 as I am reporting)

I open the editor, write some message, then click "Sign/Verify" at the bottom. A dialog appears asking for a secret key for signing. My secret key is available, I press OK. Instead of prompting me for my passphrase, Kgpg gives me the following error message: "Signing not possible: bad passphrase or missing key". Signing works fine with gpg on the command line using the same key.

Reproducible: Always

Steps to Reproduce:
1. Open the editor
2. Type a message
3. Click sign/verify
4. Choose your private key

Actual Results:  
Message box saying: "Signing not possible: bad passphrase or missing key"

Expected Results:  
My text bearing a nice gpg signature

Create a gpg signature for the message
Comment 1 Rolf Eike Beer 2013-07-05 17:07:53 UTC
Works fine for me. Please rebuild KGpg with cmake option KGPG_DEBUG_TRANSACTIONS set (i.e. cmake command like should include -DKGPG_DEBUG_TRANSACTIONS=On), then start KGpg from a konsole window (make sure it is shut down before, not just minimized to the tray) and reproduce the problem. Then please send me the info printed to the console. Please also tell me your GnuPG version.
Comment 2 Arthur Breitman 2013-07-09 22:12:01 UTC
gpg version 1.4.12 and gpg2 version 2.0.19 with libcrypt 1.5.0

I compiled kgpg from source with the cmake flag you mentioned. For some reason, now it starts but the window won't show up. Here's the console output:

arthurb@coin:~$ kgpg
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
QSystemTrayIcon::setVisible: No Icon set
arthurb@coin:~$ kgpg(14651)/kdecore (K*TimeZone*): KSystemTimeZones: ktimezoned initialize() D-Bus call failed:  "The name org.kde.kded was not provided by any .service files"
Comment 3 Arthur Breitman 2013-07-10 16:26:28 UTC
After a restart, I'm able to launched the compiled kgpg. However, I only receive the following output

arthurb@coin:~/kgpg-4.10.4/build$ ./kgpg
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
arthurb@coin:~/kgpg-4.10.4/build$ Hspell: can't open /usr/share/hspell/hebrew.wgz.sizes.
Enchant dict for "en_US" 0x16542f0
Comment 4 Rolf Eike Beer 2013-07-10 17:49:41 UTC
You still have the old instance running.
Comment 5 Arthur Breitman 2013-07-10 17:52:15 UTC
Nope

arthurb@coin:~/kgpg-4.10.4/build$ ps aux | grep kgpg
arthurb  22335  0.5  0.2 377744 25412 pts/0    Sl   13:50   0:00 ./kgpg
arthurb  22359  0.0  0.0   9436   952 pts/0    S+   13:50   0:00 grep --color=auto kgpg
arthurb@coin:~/kgpg-4.10.4/build$ killall -9 kgpg
arthurb@coin:~/kgpg-4.10.4/build$ ps aux | grep kgp
arthurb  22370  0.0  0.0   9436   952 pts/0    S+   13:50   0:00 grep --color=auto kgp
arthurb@coin:~/kgpg-4.10.4/build$ pwd
/home/arthurb/kgpg-4.10.4/build
arthurb@coin:~/kgpg-4.10.4/build$ ./kgpg
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
arthurb@coin:~/kgpg-4.10.4/build$ echo "application detaches itself from the shell at this point"
application detaches itself from the shell at this point
arthurb@coin:~/kgpg-4.10.4/build$ Hspell: can't open /usr/share/hspell/hebrew.wgz.sizes.
Enchant dict for "en_US" 0x2495190 

arthurb@coin:~/kgpg-4.10.4/build$ echo "about to sign, the preceding happened while opening the editor"
about to sign, the preceding happened while opening the editor
arthurb@coin:~/kgpg-4.10.4/build$ echo "failed, but no output"
failed, but no output
arthurb@coin:~/kgpg-4.10.4/build$
Comment 6 Rolf Eike Beer 2013-07-10 18:26:34 UTC
Run kdebugdialog, make sure 2100 (KGpg) is enabled. Then try again.
Comment 7 Arthur Breitman 2013-07-10 18:37:00 UTC
Ah, all debug output was disabled...


arthurb@coin:~/kgpg-4.10.4/build$ ./kgpg
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
QDBusConnection: session D-Bus connection created before QCoreApplication. Application may misbehave.
kgpg(24827) GnupgBinary::setBinary: checking version of GnuPG executable "gpg"
kgpg(24827) GnupgBinary::setBinary: version is "1.4.12" 66572
kgpg(24827)/kdeui (KNotification) KStatusNotifierItemDBus::KStatusNotifierItemDBus: service is "org.kde.StatusNotifierItem-24827-1"
kgpg(24827)/kdeui (KNotification) KStatusNotifierItemPrivate::registerToDaemon: Registering a client interface to the KStatusNotifierWatcher
arthurb@coin:~/kgpg-4.10.4/build$ kgpg(24827)/kdecore (K*TimeZone*) KSystemTimeZonesPrivate::instance: instance(): ... initialised
kgpg(24827)/kdecore (K*TimeZone*) KSystemTimeZonesPrivate::readConfig: readConfig(): local zone= "America/New_York"
kgpg(24827)/kdecore (K*TimeZone*) KSystemTimeZonesPrivate::readZoneTab: readZoneTab( "/usr/share/zoneinfo/zone.tab" )
kgpg(24827)/kdecore (KSycoca) KSycocaPrivate::openDatabase: Trying to open ksycoca from "/var/tmp/kdecache-arthurb/ksycoca4"
Hspell: can't open /usr/share/hspell/hebrew.wgz.sizes.
Enchant dict for "en_US" 0x24389e0 
kgpg(24827) KGpgTransaction::setSuccess: 0 0
kgpg(24827) KGpgTransaction::start: KGpgSignText(0x2a00c20) ("gpg", "--no-secmem-warning", "--no-tty", "--no-greeting", "--options", "/home/arthurb/.gnupg/gpg.conf", "--status-fd=1", "-u", "0EF73109E18FE1CB", "--clearsign")
kgpg(24827) KGpgTransactionPrivate::slotReadReady: KGpgSignText(0x2a00c20) "[GNUPG:] USERID_HINT 0EF73109E18FE1CB Arthur Breitman <arthur.breitman@gmail.com>"
kgpg(24827) KGpgTransactionPrivate::slotReadReady: KGpgSignText(0x2a00c20) "[GNUPG:] NEED_PASSPHRASE 0EF73109E18FE1CB 0EF73109E18FE1CB 1 0"
kgpg(24827) KGpgTransaction::setSuccess: 0 2
kgpg(24827)/kdeui (KNotification) KNotificationManager::close: 984
Comment 8 Sudhir Khanger 2014-11-28 12:50:26 UTC
I am using Kgpg 2.13.1 and I have this problem. KMail also refuses to send sign/encrypted message.
Comment 9 Dan Bărăgan 2015-12-14 14:43:30 UTC
I experience the same problem:
kgpg --version
Qt: 4.8.6
KDE Development Platform: 4.14.2
KGpg: 2.13.1

please note that encrypt/decrypt works fine from the same app (decrypt asking for passpharase)
Comment 10 daniel.jo 2015-12-16 16:37:12 UTC
I can confirm I have the same issue
KDE Development Platform: 4.14.2
KGpg: 2.13.1


Any chance it will be resolved fast? What would be an easy turn around in the mean time? (except recompiling from source)
It's quite critical function.
Comment 11 Rolf Eike Beer 2016-01-19 11:37:55 UTC
> Any chance it will be resolved fast? What would be an easy turn around 
> in the
> mean time? (except recompiling from source)
> It's quite critical function.

I still cannot reproduce this. Is your pinentry setup working, e.g. do 
you get a new window asking for the passphrase e.g. when you sign a key 
or decrypt a text?
Comment 12 Dan Bărăgan 2016-01-19 12:15:21 UTC
Created attachment 96730 [details]
Screenshot of steps on encrypt/decrypt vs sign.

Same key is used for encrypt/decrypt as for sign.
One can see that sign throws an error instead.
Comment 13 daniel.jo 2016-08-12 11:33:08 UTC
(In reply to Rolf Eike Beer from comment #11)
> > Any chance it will be resolved fast? What would be an easy turn around 
> > in the
> > mean time? (except recompiling from source)
> > It's quite critical function.
> 
> I still cannot reproduce this. Is your pinentry setup working, e.g. do 
> you get a new window asking for the passphrase e.g. when you sign a key 
> or decrypt a text?

No, it doesn't ask me for password when signing.

It does when decrypting and that works just fine.
Comment 14 Andrew Crouthamel 2018-09-26 22:27:14 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least 15 days. Please provide the requested information as soon as possible and set the bug status as REPORTED. Due to regular bug tracker maintenance, if the bug is still in NEEDSINFO status with no change in 30 days, the bug will be closed as RESOLVED > WORKSFORME due to lack of needed information.

For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please set the bug status as REPORTED so that the KDE team knows that the bug is ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 15 Andrew Crouthamel 2018-10-27 02:16:12 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least 30 days. The bug is now closed as RESOLVED > WORKSFORME due to lack of needed information.

For more information about our bug triaging procedures please read the wiki located here: https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!