diff options
author | Denis Efremov <efremov@linux.com> | 2020-08-27 09:43:59 +0300 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2020-09-04 17:57:16 +1000 |
commit | 57059185fb30978fea5c7eaf301d387feeaab3e1 (patch) | |
tree | 3d2880efcaa852cb376f7fa60fe4b7f6f6d39f79 /drivers/crypto/inside-secure | |
parent | d83d631b18e56aee51e4b8c89968952703e4de98 (diff) |
crypto: inside-secure - use kfree_sensitive()
Use kfree_sensitive() instead of open-coding it.
Signed-off-by: Denis Efremov <efremov@linux.com>
Acked-by: Antoine Tenart <antoine.tenart@bootlin.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'drivers/crypto/inside-secure')
-rw-r--r-- | drivers/crypto/inside-secure/safexcel_hash.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/crypto/inside-secure/safexcel_hash.c b/drivers/crypto/inside-secure/safexcel_hash.c index 16a467969d8e..5ffdc1cd5847 100644 --- a/drivers/crypto/inside-secure/safexcel_hash.c +++ b/drivers/crypto/inside-secure/safexcel_hash.c @@ -1082,8 +1082,7 @@ static int safexcel_hmac_init_pad(struct ahash_request *areq, } /* Avoid leaking */ - memzero_explicit(keydup, keylen); - kfree(keydup); + kfree_sensitive(keydup); if (ret) return ret; |