Automate fix for "GnuPG keys missing" problem
I started up Tails but cannot see my GNUPG keys. They just all randomly disappeared for no reason. Any fix would be nice.
In the few cases where users provided enough info for us to analyze anything,
~/.gnupg/pubring.kbx was empty.
Thankfully, GnuPG stores a backup of
~/.gnupg/pubring.kbx~. So we can do this: at login time, if
pubring.kbx is empty but
pubring.kbx~ is not, then we delete the former, and rename
pubring.kbx. Should tell the user know we're doing this, or even ask them for confirmation first?
if this problem happens to you, please check the size of
~/.gnupg/pubring.kbx~. If the former is empty but the latter is not, please try to delete the former and rename the latter to
~/.gnupg/pubring.kbx: this will hopefully solve the problem. Let us know!