X-Git-Url: https://git.librecmc.org/?a=blobdiff_plain;ds=sidebyside;f=crypto%2Fevp%2Fm_md2.c;h=1eae4ed38cb4e9d4dcefe63f87fed2f48d727520;hb=746fc2526ffc17d57a5fb87568d01400cbcf62fd;hp=442d234e320ed61e8983f2ba21987d082da4fc1d;hpb=dbad169019598981174ff46c7a9bf58373b0e53a;p=oweals%2Fopenssl.git diff --git a/crypto/evp/m_md2.c b/crypto/evp/m_md2.c index 442d234e32..1eae4ed38c 100644 --- a/crypto/evp/m_md2.c +++ b/crypto/evp/m_md2.c @@ -56,22 +56,37 @@ * [including the GNU Public Licence.] */ -#ifndef OPENSSL_NO_MD2 #include #include "cryptlib.h" + +#ifndef OPENSSL_NO_MD2 + #include #include #include #include +#include + +static int init(EVP_MD_CTX *ctx) + { return MD2_Init(ctx->md_data); } + +static int update(EVP_MD_CTX *ctx,const void *data,size_t count) + { return MD2_Update(ctx->md_data,data,count); } + +static int final(EVP_MD_CTX *ctx,unsigned char *md) + { return MD2_Final(md,ctx->md_data); } static const EVP_MD md2_md= { NID_md2, NID_md2WithRSAEncryption, MD2_DIGEST_LENGTH, - MD2_Init, - MD2_Update, - MD2_Final, + 0, + init, + update, + final, + NULL, + NULL, EVP_PKEY_RSA_method, MD2_BLOCK, sizeof(EVP_MD *)+sizeof(MD2_CTX),