Stricter boundary condition check in HMAC_Init_ex.
This commit is contained in:
parent
16ab8a93bc
commit
6f86850eec
1 changed files with 1 additions and 1 deletions
|
@ -89,7 +89,7 @@ void HMAC_Init_ex(HMAC_CTX *ctx, const void *key, int len,
|
|||
}
|
||||
else
|
||||
{
|
||||
OPENSSL_assert(len <= (int)sizeof(ctx->key));
|
||||
OPENSSL_assert(len>0 && len <= (int)sizeof(ctx->key));
|
||||
memcpy(ctx->key,key,len);
|
||||
ctx->key_length=len;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue