From dbad169019598981174ff46c7a9bf58373b0e53a Mon Sep 17 00:00:00 2001 From: Ben Laurie Date: Mon, 30 Jul 2001 23:57:25 +0000 Subject: Really add the EVP and all of the DES changes. --- crypto/asn1/a_verify.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'crypto/asn1/a_verify.c') diff --git a/crypto/asn1/a_verify.c b/crypto/asn1/a_verify.c index 4b4a240f50..59ba322839 100644 --- a/crypto/asn1/a_verify.c +++ b/crypto/asn1/a_verify.c @@ -81,6 +81,7 @@ int ASN1_verify(int (*i2d)(), X509_ALGOR *a, ASN1_BIT_STRING *signature, unsigned char *p,*buf_in=NULL; int ret= -1,i,inl; + EVP_MD_CTX_init(&ctx); i=OBJ_obj2nid(a->algorithm); type=EVP_get_digestbyname(OBJ_nid2sn(i)); if (type == NULL) @@ -117,6 +118,7 @@ int ASN1_verify(int (*i2d)(), X509_ALGOR *a, ASN1_BIT_STRING *signature, /* memset(&ctx,0,sizeof(ctx)); */ ret=1; err: + EVP_MD_CTX_cleanup(&ctx); return(ret); } @@ -131,6 +133,7 @@ int ASN1_item_verify(const ASN1_ITEM *it, X509_ALGOR *a, ASN1_BIT_STRING *signat unsigned char *buf_in=NULL; int ret= -1,i,inl; + EVP_MD_CTX_init(&ctx); i=OBJ_obj2nid(a->algorithm); type=EVP_get_digestbyname(OBJ_nid2sn(i)); if (type == NULL) @@ -165,6 +168,7 @@ int ASN1_item_verify(const ASN1_ITEM *it, X509_ALGOR *a, ASN1_BIT_STRING *signat /* memset(&ctx,0,sizeof(ctx)); */ ret=1; err: + EVP_MD_CTX_cleanup(&ctx); return(ret); } -- cgit v1.2.3