I lost my public key! :)

Werner Koch wk@gnupg.org
Wed Oct 23 10:57:02 2002


On Tue, 22 Oct 2002 23:33:44 -0400, David Shaw said:

> All OpenPGP secret keys have a copy of the public key inside them, and
> in a worst-case scenario, you can create yourself a new public key
> using the secret key.  Some versions of PGP, in fact, do this

I just wrote a tool to convert a secret key into a public one.  It is
actually a new option for gpgsplit and available in the CVS. It will
also be included in 1.2.1 I hope to release soon.

It works like this

  gpgsplit --no-split --secret-to-public secret.gpg >publickey.gpg

One should first try to export the secret key and convert just this
one.  Using the entire secring should work too.  After this has been
done, the publickey.gpg can be imported into gpg as usual. 


Salam-Shalom,

   Werner