Lines Matching refs:digest
1 /* crypto/evp/digest.c */
149 if (ctx->engine && ctx->digest && (!type ||
150 (type && (type->type == ctx->digest->type))))
181 /* We'll use the ENGINE's private digest definition */
192 if(!ctx->digest)
198 if (ctx->digest != type)
200 if (ctx->digest && ctx->digest->ctx_size)
202 ctx->digest=type;
228 return ctx->digest->init(ctx);
250 OPENSSL_assert(ctx->digest->md_size <= EVP_MAX_MD_SIZE);
251 ret=ctx->digest->final(ctx,md);
253 *size=ctx->digest->md_size;
254 if (ctx->digest->cleanup)
256 ctx->digest->cleanup(ctx);
259 memset(ctx->md_data,0,ctx->digest->ctx_size);
272 if ((in == NULL) || (in->digest == NULL))
278 /* Make sure it's safe to copy a digest context using an ENGINE */
286 if (out->digest == in->digest)
295 if (in->md_data && out->digest->ctx_size)
301 out->md_data=OPENSSL_malloc(out->digest->ctx_size);
308 memcpy(out->md_data,in->md_data,out->digest->ctx_size);
323 if (out->digest->copy)
324 return out->digest->copy(out,in);
360 if (ctx->digest && ctx->digest->cleanup
362 ctx->digest->cleanup(ctx);
363 if (ctx->digest && ctx->digest->ctx_size && ctx->md_data
366 OPENSSL_cleanse(ctx->md_data,ctx->digest->ctx_size);