mirror of
git://git.gnupg.org/gnupg.git
synced 2025-01-03 12:11:33 +01:00
gpg: Always use version >= 4 to generate signature.
* g10/sign.c (update_keysig_packet): Make sure sig->version >= 4. -- GnuPG-bug-id: 5809 Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>
This commit is contained in:
parent
06b70daa50
commit
0ba69e5581
@ -1928,6 +1928,15 @@ update_keysig_packet (ctrl_t ctrl,
|
||||
/* Create a new signature packet. */
|
||||
sig = copy_signature (NULL, orig_sig);
|
||||
|
||||
/* Don't generate version 3 signature, but newer. */
|
||||
if (sig->version == 3)
|
||||
{
|
||||
if (pk->version > 3)
|
||||
sig->version = pk->version;
|
||||
else
|
||||
sig->version = 4;
|
||||
}
|
||||
|
||||
sig->digest_algo = digest_algo;
|
||||
|
||||
/* We need to create a new timestamp so that new sig expiration
|
||||
|
Loading…
x
Reference in New Issue
Block a user