Renewing an expired GPG subkey

I set my GPG key to expire annually, which was all well and good until it actually expired and I found myself needing to renew it. I was able to renew the primary key by expiring it, but unfortunately this only expired the primary key; the subkey remained expired, which in turn meant my key wasn’t any good.  After digging around for a while, I discovered this email thread that explains how to extend the expiration date, which I’ll summarize here:

  1. gpg –list-keys
    • this gives you a list of all the keys on your computer. you need this to find the keyname that you are trying to update.
  2. gpg –edit-key [keyname]
  3. command> list
    • lists the available subkeys
  4. command> key [subkey]
    • choose the number of the subkey you want to edit; e.g. key 1
  5. command> expire
    • expire lets you set a new experation date for the subkey.
  6. command> save

It’s straightforward … once you know how to do it. 🙂

1 thought on “Renewing an expired GPG subkey

  1. This will not help a newbie.
    You’d better define what you mean by “key [subkey] ”

    After the “key” user must enter an number from 1 and above.
    Start with 1 and then do again “list” . If you have used the right number a * must be in front of the selected key.
    Then do rest to change the expiration date.

Comments are closed.