3

I just created a master key and two subkeys. The first subkey is used for encryption, the second one for signing.

Now I am wondering what public key do I have to publish on my website. Does is suffice to publish to public key of the master key or do I have to publish the public key of each subkey?

migrated from crypto.stackexchange.com Apr 15 '15 at 17:25

This question came from our site for software developers, mathematicians and others interested in cryptography.

4

As I understand the scheme, you now have three pairs of keys: A Master public/private, and two Subkey public/private pairs. Please correct me if I misunderstood.

According to https://wiki.debian.org/Subkeys , it seems like you should publish both of your public subkeys in order for others to both

  1. encrypt messages meant only for you, and
  2. verify your signatures.

Subkeys make this easier: you already have an automatically created encryption subkey and you create another subkey for signing, and you keep those on your main computer. You publish the subkeys on the normal keyservers, and everyone else will use them instead of the master keys for encrypting messages or verifying your message signatures. Likewise, you will use the subkeys for decrypting and signing messages. [emphasis mine]

Furthermore, do not publish either of your master keys: (again, https://wiki.debian.org/Subkeys)

You will need to use the master keys only in exceptional circumstances, namely when you want to modify your own or someone else's key. More specifically, you need the master private key:

  1. when you sign someone else's key or revoke an existing signature,
  2. when you add a new UID or mark an existing UID as primary,
  3. when you create a new subkey,
  4. when you revoke an existing UID or subkey,
  5. when you change the preferences (e.g., with setpref) on a UID,
  6. when you change the expiration date on your master key or any of its subkey, or
  7. when you revoke or generate a revocation certificate for the complete key.

(Because each of these operation is done by adding a new self- or revocation signatures from the private master key.)

  • 5
    I was reading some more about this topic and I suppose your answer must be slightly modified. When exporting the public part of the master key and its subkeys, you quickly recognize that they are equal. So there is only one public key. As far as i understood GPG encodes all subkeys in this public key. In conclusion you can just export and publish the public part of the master key. – null Apr 11 '15 at 18:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.