From 9371521dd134559b5908e43cafa9d09699f7976b Mon Sep 17 00:00:00 2001 From: csoler Date: Mon, 20 Feb 2017 23:19:29 +0100 Subject: [PATCH] fixed bug causing crash in openssl_crypto due to not zeroing a field that was not duplicated before delete --- openpgpsdk/src/openpgpsdk/openssl_crypto.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/openpgpsdk/src/openpgpsdk/openssl_crypto.c b/openpgpsdk/src/openpgpsdk/openssl_crypto.c index 768abab8e..4b36d2caf 100644 --- a/openpgpsdk/src/openpgpsdk/openssl_crypto.c +++ b/openpgpsdk/src/openpgpsdk/openssl_crypto.c @@ -416,6 +416,12 @@ ops_boolean_t ops_dsa_verify(const unsigned char *hash,size_t hash_length, fprintf(stderr,"(WW) ops_dsa_verify: openssl does only supports 'q' of 160 bits. Current is %d bits.\n",BN_num_bits(dsa->q)) ; already_said=ops_true ; } + +#if OPENSSL_VERSION_NUMBER < 0x10100000L + osig->r=NULL; // in this case, the values are not copied. + osig->s=NULL; +#endif + DSA_SIG_free(osig); return ops_false ; }