aboutsummaryrefslogtreecommitdiffstats
path: root/g10/keyid.c
diff options
context:
space:
mode:
authorDavid Shaw <[email protected]>2005-08-27 03:09:40 +0000
committerDavid Shaw <[email protected]>2005-08-27 03:09:40 +0000
commitf74282bee03f26af0887dfcc806c89ad0bc142d3 (patch)
treefe83661e8e82fcf199880c26fa26d7dc8215b204 /g10/keyid.c
parent* keyedit.c (ask_revoke_sig): Add a revsig --with-colons mode. (diff)
downloadgnupg-f74282bee03f26af0887dfcc806c89ad0bc142d3.tar.gz
gnupg-f74282bee03f26af0887dfcc806c89ad0bc142d3.zip
* misc.c (openpgp_pk_algo_usage): Default to allowing CERT for signing
algorithms. * keyedit.c (sign_uids): Don't request a signing key to make a certification. * keygen.c (do_add_key_flags): Force the certify flag on for all primary keys, as the spec requires primary keys must be able to certify (if nothing else, which key is going to issue the user ID signature?) (print_key_flags): Show certify flag. (ask_key_flags, ask_algo): Don't allow setting the C flag for subkeys. * keyid.c (usagestr_from_pk), getkey.c (parse_key_usage): Distinguish between a sign/certify key and a certify-only key.
Diffstat (limited to 'g10/keyid.c')
-rw-r--r--g10/keyid.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/g10/keyid.c b/g10/keyid.c
index 7d5b905a5..7c2bd3ba4 100644
--- a/g10/keyid.c
+++ b/g10/keyid.c
@@ -547,10 +547,13 @@ usagestr_from_pk( PKT_public_key *pk )
if ( use & PUBKEY_USAGE_SIG )
{
if (pk->is_primary)
- buffer[i++] = 'C';
+ use|=PUBKEY_USAGE_CERT;
buffer[i++] = 'S';
}
+ if ( use & PUBKEY_USAGE_CERT )
+ buffer[i++] = 'C';
+
if ( use & PUBKEY_USAGE_ENC )
buffer[i++] = 'E';