* sign.c (make_keysig_packet): Don't use MD5 for a RSA_S key as that
authorDavid Shaw <dshaw@jabberwocky.com>
Tue, 7 Mar 2006 01:16:31 +0000 (01:16 +0000)
committerDavid Shaw <dshaw@jabberwocky.com>
Tue, 7 Mar 2006 01:16:31 +0000 (01:16 +0000)
is not a PGP 2.x algorithm.

g10/ChangeLog
g10/sign.c

index 71a0770..7bb6f4e 100644 (file)
@@ -1,5 +1,8 @@
 2006-03-06  David Shaw  <dshaw@jabberwocky.com>
 
+       * sign.c (make_keysig_packet): Don't use MD5 for a RSA_S key as
+       that is not a PGP 2.x algorithm.
+
        * mainproc.c (proc_compressed): "Uncompressed" is not a valid
        compression algorithm.
 
index 2e64abb..24c37c1 100644 (file)
@@ -1374,9 +1374,8 @@ make_keysig_packet( PKT_signature **ret_sig, PKT_public_key *pk,
 
        if(opt.cert_digest_algo)
          digest_algo=opt.cert_digest_algo;
-       else if((sk->pubkey_algo==PUBKEY_ALGO_RSA ||
-                sk->pubkey_algo==PUBKEY_ALGO_RSA_S) &&
-               pk->version<4 && sigversion < 4)
+       else if(sk->pubkey_algo==PUBKEY_ALGO_RSA
+               && pk->version<4 && sigversion<4)
          digest_algo = DIGEST_ALGO_MD5;
        else
          digest_algo = DIGEST_ALGO_SHA1;