Today, I was greeted with the following as I was trying to save an crypted file from Emacs:
Error while encrypting with "gpg2": gpg: XXX: übersprungen: unbrauchbarer öffentlicher Schlüssel gpg: [stdin]: encryption failed: unbrauchbarer öffentlicher Schlüssel
What? Confirmation was easy. The key had expired.
$ gpg --list-keys XXX
Superuser to the rescue. Edit the key, change the expiration date, save, verify, and send to key servers.
$ gpg --edit-key XXX gpg> expire (follow prompts) gpg> save $ gpg --list-keys XXX $ gpg --keyserver pgp.mit.edu --send-keys