Page MenuHome GnuPG

Gpg4win fails to connect to keyboxd on a cold boot
Open, Needs TriagePublic

Description

On the latest version of Gpg4win, attempting to sign a git commit with my default GPG key results in the shell hanging for around 30 seconds (or up to a minute) until the following error is shown:

> git commit
error: gpg failed to sign the data:
gpg: can't connect to the keyboxd: IPC connect call failed?
gpg: error opening key DB: No Keybox daemon running?
gpg: skipped "MYKEYPUBID": Input/output error?
[GNUPG:] INV_SGNR 0 MYKEYPUBID?
[GNUPG:] FAILURE sign 33587249?
gpg: signing failed: Input/output error?

fatal: failed to write commit object

On my laptop, I can sometimes mitigate this by opening Kleopatra and then immediately closing it, which causes the pinentry screen to appear. However, on my desktop, this usually does not work and the first sign will almost always fail.

From the second sign onward, the pinentry screen will properly show up and I will be able to sign my commit with GPG. Once I have successfully used my GPG key, subsequent invocations will *always* work until I restart my computer.

This affects two different Windows machines that I have. I'm using the following routine to get git to automatically sign my commits with my key.

Details

Version
4.4.1