tag:gpgtools.tenderapp.com,2011-11-04:/discussions/beta/491-beta-error-unable-to-sign-emailsGPGTools: Discussion 2014-12-24T08:42:35Ztag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T19:34:18Z2014-12-14T19:34:18ZBeta Error - Unable to sign emails<div><p>Hi Pertinax,</p>
<p>we're sorry you're running into this problem.<br>
The solution is to log off and log back on, but would it be
possible to run the following commands first?</p>
<pre>
<code>ps aux | grep -i pinentry
ps aux | grep gpg</code>
</pre>
<p>Thanks.</p></div>Luke Letag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T20:06:39Z2014-12-14T20:06:39ZBeta Error - Unable to sign emails<div><p>OK the results are (srm is the root user)</p>
<p>srm 8407 0.0 0.0 2433796 544 s000 R+ 8:04pm 0:00.00 grep -i
pinentry<br>
srm 717 0.0 0.1 2495796 2900 ?? S Wed02am 0:10.46
/Library/Application
Support/GPGTools/org.gpgtools.Libmacgpg.xpc<br>
srm 456 0.0 0.0 2536464 708 ?? Ss Tue11pm 0:30.30
/usr/local/MacGPG2/bin/gpg-agent --daemon<br>
srm 388 0.0 0.0 2436440 4 ?? S Tue11pm 0:00.01 /bin/bash
/usr/local/MacGPG2/libexec/shutdown-gpg-agent<br>
srm 8409 0.0 0.0 2432772 648 s000 S+ 8:04pm 0:00.00 grep gpg</p></div>Pertinax77tag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T20:10:00Z2014-12-14T20:10:00ZBeta Error - Unable to sign emails<div><p>If you have gdb installed, would yo mind running the following
commands as well:</p>
<pre>
<code>gdb /usr/local/MacGPG2/bin/gpg-agent 456</code>
</pre>
<p>and then</p>
<pre>
<code>info threads
bt</code>
</pre></div>Luke Letag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T20:32:39Z2014-12-14T20:32:39ZBeta Error - Unable to sign emails<div><p>I don't think gdb exists and I've read it has been discontinued
by Apple. Should I install it (via Macports or Homebrew)?</p></div>Pertinax77tag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T20:39:56Z2014-12-14T20:39:56ZBeta Error - Unable to sign emails<div><p>Ah, my bad.</p>
<p>do you have lldb by any chance?</p></div>Luke Letag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T20:52:53Z2014-12-14T20:52:53ZBeta Error - Unable to sign emails<div><p>yes</p></div>Pertinax77tag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T20:54:51Z2014-12-14T20:54:51ZBeta Error - Unable to sign emails<div><p>perfect! Than the following commands should work:</p>
<pre>
<code>process attach --pid 456
thread list
thread backtrace</code>
</pre>
<p>Please post the output, it might finally give us an idea why
this is happening.</p>
<p>Thank you very much for the help!</p></div>Luke Letag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T21:30:10Z2014-12-14T21:30:10ZBeta Error - Unable to sign emails<div><p>OK here is the output in lldb</p>
<p>(lldb) process attach --pid 456 error: attach failed: lost
connection</p></div>Pertinax77tag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T22:00:23Z2014-12-14T22:00:23ZBeta Error - Unable to sign emails<div><p>hmm.. seems like the pid 456 is no longer a valid process.<br>
Could you run</p>
<pre>
<code>ps aux | grep -i gpg-agent</code>
</pre>
<p>again and replace 456 with the pid you see from that output?<br>
Oh and is the error still happening?</p></div>Luke Letag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T22:06:26Z2014-12-14T22:06:26ZBeta Error - Unable to sign emails<div><p>(lldb) process attach --pid 396 Process 396 stopped<br>
Executable module set to "/usr/local/MacGPG2/bin/gpg-agent".<br>
Architecture set to: x86_64-apple-macosx.<br>
(lldb) thread list Process 396 stopped<br>
* thread #1: tid = 0x0d2a, 0x00007fff925043f6
libsystem_kernel.dylib<code>__select + 10, queue =
'com.apple.main-thread', stop reason = signal SIGSTOP (lldb) thread
backtrace * thread #1: tid = 0x0d2a, 0x00007fff925043f6
libsystem_kernel.dylib</code>__select + 10, queue =
'com.apple.main-thread', stop reason = signal SIGSTOP * frame #0:
0x00007fff925043f6 libsystem_kernel.dylib<code>__select + 10 frame
#1: 0x000000010011010c
libpth.20.0.27.dylib</code>__pth_sched_eventmanager + 1909 frame
#2: 0x000000010010f8f8 libpth.20.0.27.dylib<code>__pth_scheduler +
1082 frame #3: 0x00000001001119f5
libpth.20.0.27.dylib</code>pth_spawn_trampoline + 27 frame #4:
0x000000010010edda libpth.20.0.27.dylib<code>pth_mctx_set_bootstrap
+ 126 frame #5: 0x000000010010ed5c
libpth.20.0.27.dylib</code>pth_mctx_set_trampoline + 37 frame #6:
0x00007fff9016ff2d libsystem_platform.dylib<code>_sigtramp + 45
frame #7: 0x00007fff92504727
libsystem_kernel.dylib</code>__sigsuspend + 11 (lldb)</p></div>Pertinax77tag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T22:59:14Z2014-12-14T22:59:14ZBeta Error - Unable to sign emails<div><p>Thanks, unfortunately it's the same I'm seeing here.</p>
<p>What does the following command say:</p>
<pre>
<code>echo "HELLO" | /usr/local/MacGPG2/libexec/pinentry-mac.app/Contents/MacOS/pinentry-mac</code>
</pre></div>Luke Letag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-14T23:48:29Z2014-12-14T23:48:29ZBeta Error - Unable to sign emails<div><p>OK Your orders please<br>
ERR 83886355 unknown command</p></div>Pertinax77tag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-15T06:53:33Z2014-12-15T06:53:33ZBeta Error - Unable to sign emails<div><p>So that's working as well.<br>
And when you try to sign an email, it's still not working?</p>
<p>If so, would you mind coming into our live chat?<br>
<a href=
"http://www.hipchat.com/gi8zHW4K3">http://www.hipchat.com/gi8zHW4K3</a></p>
<p>It'd be great to try some more things.</p></div>Luke Letag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-15T10:05:56Z2014-12-15T10:05:56ZBeta Error - Unable to sign emails<div><p>Strangely, signatures seem to be working again - I sent an email
today (using Apple Mail) and a signature was attached.</p>
<p>Do you have a way of checking the status of GPG on the
system?</p></div>Pertinax77tag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-15T10:21:46Z2014-12-15T10:21:46ZBeta Error - Unable to sign emails<div><p>Hi</p>
<p>Signatures do seem to be working again but I don't know what
caused the problem in the first place.</p>
<p>Here is the output from running those initial two commands you
gave me.</p>
<p>~ srm$ ps aux | grep gpg srm 443 0.0 0.0 2435416 4 ?? S 8:56pm
0:00.01 /bin/bash /usr/local/MacGPG2/libexec/shutdown-gpg-agent<br>
srm 396 0.0 0.0 2486264 856 ?? Ss 8:56pm 0:01.41 gpg-agent
--daemon<br>
srm 382 0.0 0.1 2496164 3612 ?? S 8:56pm 0:01.80
/Library/Application
Support/GPGTools/org.gpgtools.Libmacgpg.xpc<br>
srm 1906 0.0 0.0 2432772 644 s000 S+ 10:18am 0:00.00 grep gpg</p>
<p>Is it possible that the keychain could have been
compromised?</p></div>Pertinax77tag:gpgtools.tenderapp.com,2011-11-04:Comment/355409142014-12-24T08:42:22Z2014-12-24T08:42:22ZBeta Error - Unable to sign emails<div><p>Hi Pertinax,</p>
<p>I don't think the keychain had been compromised. But it would
indeed be interesting to know what went wrong in the first
place.</p>
<p>Please make sure to let us know should this behavior
re-occur.</p>
<p>All the best,<br>
steve</p></div>Steve