diff options
Diffstat (limited to 'crypto/evp/digest.c')
-rw-r--r-- | crypto/evp/digest.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/crypto/evp/digest.c b/crypto/evp/digest.c index a969ac69ed..9d18728d30 100644 --- a/crypto/evp/digest.c +++ b/crypto/evp/digest.c @@ -219,6 +219,8 @@ int EVP_DigestFinal(EVP_MD_CTX *ctx, unsigned char *md, unsigned int *size) int EVP_DigestFinal_ex(EVP_MD_CTX *ctx, unsigned char *md, unsigned int *size) { int ret; + + OPENSSL_assert(ctx->digest->md_size <= EVP_MAX_MD_SIZE); ret=ctx->digest->final(ctx,md); if (size != NULL) *size=ctx->digest->md_size; |