aboutsummaryrefslogtreecommitdiffstats
path: root/crypto/evp/p_verify.c
diff options
context:
space:
mode:
Diffstat (limited to 'crypto/evp/p_verify.c')
-rw-r--r--crypto/evp/p_verify.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/crypto/evp/p_verify.c b/crypto/evp/p_verify.c
index dcb54f3abb..af175b84f7 100644
--- a/crypto/evp/p_verify.c
+++ b/crypto/evp/p_verify.c
@@ -85,8 +85,10 @@ int EVP_VerifyFinal(EVP_MD_CTX *ctx, unsigned char *sigbuf,
EVPerr(EVP_F_EVP_VERIFYFINAL,EVP_R_WRONG_PUBLIC_KEY_TYPE);
return(-1);
}
+ EVP_MD_CTX_init(&tmp_ctx);
EVP_MD_CTX_copy(&tmp_ctx,ctx);
EVP_DigestFinal(&tmp_ctx,&(m[0]),&m_len);
+ EVP_MD_CTX_cleanup(&tmp_ctx);
if (ctx->digest->verify == NULL)
{
EVPerr(EVP_F_EVP_VERIFYFINAL,EVP_R_NO_VERIFY_FUNCTION_CONFIGURED);