mirror of
git://git.gnupg.org/gnupg.git
synced 2025-07-03 22:56:33 +02:00
* build-packet.c (build_sig_subpkt): Delete subpackets from both hashed
and unhashed area on update. (find_subpkt): No longer needed. * keyedit.c (sign_uids): With --pgp2 on, refuse to sign a v3 key with a v4 signature. As usual, --expert overrides. Try to tweak some strings to a closer match so they can all be translated in one place. Use different helptext keys to allow different help text for different questions. * keygen.c (keygen_upd_std_prefs): Remove preferences from both hashed and unhashed areas if they are not going to be used.
This commit is contained in:
parent
018f352294
commit
5005434c7e
4 changed files with 101 additions and 114 deletions
13
g10/keygen.c
13
g10/keygen.c
|
@ -328,15 +328,26 @@ keygen_upd_std_prefs( PKT_signature *sig, void *opaque )
|
|||
if (nsym_prefs)
|
||||
build_sig_subpkt (sig, SIGSUBPKT_PREF_SYM, sym_prefs, nsym_prefs);
|
||||
else
|
||||
{
|
||||
delete_sig_subpkt (sig->hashed, SIGSUBPKT_PREF_SYM);
|
||||
delete_sig_subpkt (sig->unhashed, SIGSUBPKT_PREF_SYM);
|
||||
}
|
||||
|
||||
if (nhash_prefs)
|
||||
build_sig_subpkt (sig, SIGSUBPKT_PREF_HASH, hash_prefs, nhash_prefs);
|
||||
else
|
||||
delete_sig_subpkt (sig->hashed, SIGSUBPKT_PREF_HASH);
|
||||
{
|
||||
delete_sig_subpkt (sig->hashed, SIGSUBPKT_PREF_HASH);
|
||||
delete_sig_subpkt (sig->unhashed, SIGSUBPKT_PREF_HASH);
|
||||
}
|
||||
|
||||
if (nzip_prefs)
|
||||
build_sig_subpkt (sig, SIGSUBPKT_PREF_COMPR, zip_prefs, nzip_prefs);
|
||||
else
|
||||
{
|
||||
delete_sig_subpkt (sig->hashed, SIGSUBPKT_PREF_COMPR);
|
||||
delete_sig_subpkt (sig->unhashed, SIGSUBPKT_PREF_COMPR);
|
||||
}
|
||||
|
||||
/* Make sure that the MDC feature flag is set */
|
||||
add_feature_mdc (sig);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue