From: Jonathan McDowell Date: Sat, 14 Jul 2012 19:20:27 +0000 (-0600) Subject: Fix the size of the hash array when checking sig hashes X-Git-Tag: onak-0.4.2~18 X-Git-Url: https://the.earth.li/gitweb/?a=commitdiff_plain;h=666b0d041ecf22f2b4936d3b04a98e5807f55877;p=onak.git Fix the size of the hash array when checking sig hashes It was only 20 bytes - big enough for SHA1, but not when the larger SHA2 hashes are available in nettle. This allows up to SHA512. --- diff --git a/sigcheck.c b/sigcheck.c index e5e8ccd..852b53b 100644 --- a/sigcheck.c +++ b/sigcheck.c @@ -57,7 +57,7 @@ int check_packet_sighash(struct openpgp_publickey *key, uint8_t keyheader[3]; uint8_t packetheader[5]; uint8_t v4trailer[6]; - uint8_t hash[20]; + uint8_t hash[64]; uint8_t *hashdata[8]; size_t hashlen[8]; int chunks, i;