tag:gpgtools.tenderapp.com,2011-11-04:/discussions/problems/132913-gpg-cli-actions-timing-outGPGTools: Discussion 2023-04-26T13:04:05Ztag:gpgtools.tenderapp.com,2011-11-04:Comment/584421922023-04-03T13:30:21Z2023-04-03T13:30:21Zgpg CLI actions timing out?<div><p>Hi gpg_dude,</p>
<p>hmm... this is rather strange. Could you send a screenshot of the 2 UI prompts you are seeing?<br>
It might be somehow possible that GPG Keychain and the cli compete over a lock or something like that, but from your description alone I can't see that.</p></div>Luke Letag:gpgtools.tenderapp.com,2011-11-04:Comment/584421922023-04-03T17:27:00Z2023-04-03T17:27:00Zgpg CLI actions timing out?<div><p>See attached - also included the CLI prompts which I assume the UI ones are mirroring</p></div>gpg_dudetag:gpgtools.tenderapp.com,2011-11-04:Comment/584421922023-04-17T15:32:44Z2023-04-17T15:32:44Zgpg CLI actions timing out?<div><p>Hi gpg_dude,</p>
<p>ok, so apparently our support platform just swallowed my answer to you.<br>
The behavior you saw is in fact the result of timeout of pinentry-mac in combination with gpg-agent. Since the default for both operations is no, as seen by the capitalized letters, a timeout results in the default to be accepted presumably.</p></div>Luke Letag:gpgtools.tenderapp.com,2011-11-04:Comment/584421922023-04-24T19:36:40Z2023-04-24T19:36:49Zgpg CLI actions timing out?<div><p>Is it possible to change this behavior so the prompts generated by a CLI invocation of gpg2 are only shown in the CLI terminal vs. the CLI <em>and</em> the GUI? I've tried adding --pinentry-mode loopback but that just fails outright:</p>
<p>Delete this key from the keyring? (y/N) y</p>
<p>This is a secret key! - really delete? (y/N) y</p>
<p>gpg: deleting secret key failed: No pinentry</p>
<p>gpg: deleting secret subkey failed: No pinentry</p>
<p>gpg: 0x86AFCDFB: delete key failed: No pinentry</p></div>gpg_dudetag:gpgtools.tenderapp.com,2011-11-04:Comment/584421922023-04-25T20:58:43Z2023-04-25T20:58:43Zgpg CLI actions timing out?<div><p>Yes that is possible by telling pinentry to use curses:<br>
<code>export PINENTRY_USER_DATA="USE_CURSES=1"</code></p>
<p>Please let us know if that worked.</p>
<p>Cheers</p></div>Luke Letag:gpgtools.tenderapp.com,2011-11-04:Comment/584421922023-04-25T21:56:33Z2023-04-25T21:56:33Zgpg CLI actions timing out?<div><p>That does seem to change the 3rd & 4th prompts from UI pop-ups to curses-based ones. Thanks!</p></div>gpg_dudetag:gpgtools.tenderapp.com,2011-11-04:Comment/584421922023-04-26T07:59:18Z2023-04-26T07:59:18Zgpg CLI actions timing out?<div><p>Great to hear that!</p>
<p>Closing this discussion. Feel free to open a new one at any time should you run into problems or have questions.</p></div>Luke Le