[PATCH] Allow SHA2 hash functions on gnupg 2 with scdaemon

Diego Elio Pettenò flameeyes at gmail.com
Mon Sep 27 19:04:06 CEST 2010


I'm attaching a patch that implement support for the SHA2 hash functions
in GnuPG 2 when using scdaemon.

A similar issue was reported and fixed (although in a different, IMHO
less optimal, way) in early 2010 [1] but the same issue held true for
GnuPG 2.

Without this patch, if ~/.gnupg/gpg.conf contains these lines:

  personal-digest-preferences SHA256
  cert-digest-algo SHA256
  default-preference-list SHA512 SHA384 SHA256 SHA224 AES256 AES192 AES
CAST5 ZLIB BZIP2 ZIP Uncompressed

then a sign action would report this:

  gpg: checking created signature failed: Bad signature
  gpg: signing failed: Bad signature
  gpg: [stdin]: clearsign failed: Bad signature

after applying the patch.. well, this email is signed, I hope :)

As it is, it applies fine over 2.0.16 and svn branch.


[1] http://www.gossamer-threads.com/lists/gnupg/users/51293

Diego Elio Pettenò — “Flameeyes”

If you found a .asc file in this mail and know not what it is,
it's a GnuPG digital signature: http://www.gnupg.org/

-------------- next part --------------
A non-text attachment was scrubbed...
Name: gnupg-2.0.16-opengpgv2-sha2.patch
Type: text/x-patch
Size: 1291 bytes
Desc: not available
URL: </pipermail/attachments/20100927/e88ca5e2/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 490 bytes
Desc: This is a digitally signed message part
URL: </pipermail/attachments/20100927/e88ca5e2/attachment.pgp>

More information about the Gnupg-devel mailing list