projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d28fc3d
)
crypto: authenc - don't leak pointers to authenc keys
author
Tudor-Dan Ambarus
<
[email protected]
>
Tue, 3 Apr 2018 06:39:00 +0000
(09:39 +0300)
committer
Herbert Xu
<
[email protected]
>
Fri, 20 Apr 2018 16:58:30 +0000
(
00:58
+0800)
In crypto_authenc_setkey we save pointers to the authenc keys in
a local variable of type struct crypto_authenc_keys and we don't
zeroize it after use. Fix this and don't leak pointers to the
authenc keys.
Signed-off-by: Tudor Ambarus <
[email protected]
>
Signed-off-by: Herbert Xu <
[email protected]
>
crypto/authenc.c
patch
|
blob
|
history
diff --git
a/crypto/authenc.c
b/crypto/authenc.c
index d3d6d72fe649ff00e87bf3a2eb0db591da11081e..4fa8d40d947b7594f8a7b089a8a86e8ea1b5e81d 100644
(file)
--- a/
crypto/authenc.c
+++ b/
crypto/authenc.c
@@
-108,6
+108,7
@@
static int crypto_authenc_setkey(struct crypto_aead *authenc, const u8 *key,
CRYPTO_TFM_RES_MASK);
out:
+ memzero_explicit(&keys, sizeof(keys));
return err;
badkey: