summaryrefslogtreecommitdiffstats
path: root/crypto/hmac
diff options
context:
space:
mode:
authorAndy Polyakov <appro@openssl.org>2016-06-08 20:38:12 +0200
committerAndy Polyakov <appro@openssl.org>2016-06-09 21:22:24 +0200
commit85cbc182dab1409b98a14c5a891d1219617bd458 (patch)
treeb930bff62b025ca5d99007f48988dbbf3866e658 /crypto/hmac
parent5c753de668322bf9903a49ba713b2cbc62667571 (diff)
hmac/hmac.c: fix sizeof typo in hmac_ctx_cleanup.
Reviewed-by: Matt Caswell <matt@openssl.org>
Diffstat (limited to 'crypto/hmac')
-rw-r--r--crypto/hmac/hmac.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/crypto/hmac/hmac.c b/crypto/hmac/hmac.c
index 848b581947..da7f58688f 100644
--- a/crypto/hmac/hmac.c
+++ b/crypto/hmac/hmac.c
@@ -141,7 +141,7 @@ static void hmac_ctx_cleanup(HMAC_CTX *ctx)
EVP_MD_CTX_reset(ctx->md_ctx);
ctx->md = NULL;
ctx->key_length = 0;
- memset(ctx->key, 0, sizeof(HMAC_MAX_MD_CBLOCK));
+ OPENSSL_cleanse(ctx->key, sizeof(ctx->key));
}
void HMAC_CTX_free(HMAC_CTX *ctx)