Information Security Stack Exchange is a question and answer site for information security professionals. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've been reading this page about subkeys and I was surprised to read that "GnuPG actually uses a signing-only key as the master key". I can understand how this was the case when DSA was the default (at least for GPG) for the master key, since DSA is a signing algorithm. But now, RSA is standard and RSA if I understand correctly RSA can both encrypt and sign. If I publish my public key (which I guess includes my subkeys??), how does the client know which key, master or subkey, which may be both RSA, to use to encrypt their message? For that matter, what if I have multiple RSA and el-gamal master and subkeys?

share|improve this question
up vote 3 down vote accepted

In the OpenPGP format, public keys are distributed with signatures; every key is signed by another key. A "master" key is a key which is signed by itself. The signature includes some flags which tell what the signed key may be used for; these are described in section Thus, a key intended for signatures only will be distributed with the flag "This key may be used to sign data" but not with the flag "This key may be used to encrypt communications". What you consider as the "master key" will be flagged "key meant to certify other keys" but will not be advertised as fit for encryption, even if the underlying key type mathematically allows it (e.g. RSA key).

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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