[4.2.y-ckt stable] Patch "ext4 crypto: exit cleanly if ext4_derive_key_aes() fails" has been added to the 4.2.y-ckt tree
Kamal Mostafa
kamal at canonical.com
Wed Jan 27 00:09:40 UTC 2016
This is a note to let you know that I have just added a patch titled
ext4 crypto: exit cleanly if ext4_derive_key_aes() fails
to the linux-4.2.y-queue branch of the 4.2.y-ckt extended stable tree
which can be found at:
http://kernel.ubuntu.com/git/ubuntu/linux.git/log/?h=linux-4.2.y-queue
This patch is scheduled to be released in version 4.2.8-ckt3.
If you, or anyone else, feels it should not be added to this tree, please
reply to this email.
For more information about the 4.2.y-ckt tree, see
https://wiki.ubuntu.com/Kernel/Dev/ExtendedStable
Thanks.
-Kamal
---8<------------------------------------------------------------
>From d5d7ed70c52b5dc5b6a98cf7c076b67356ce4153 Mon Sep 17 00:00:00 2001
From: Laurent Navet <laurent.navet at gmail.com>
Date: Wed, 22 Jul 2015 00:08:08 -0400
Subject: ext4 crypto: exit cleanly if ext4_derive_key_aes() fails
commit d76d99b219e1a233a720775c0451c310d34594e8 upstream.
Return value of ext4_derive_key_aes() is stored but not used.
Add test to exit cleanly if ext4_derive_key_aes() fail.
Also fix coverity CID 1309760.
Signed-off-by: Laurent Navet <laurent.navet at gmail.com>
Signed-off-by: Theodore Ts'o <tytso at mit.edu>
Signed-off-by: Kamal Mostafa <kamal at canonical.com>
---
fs/ext4/crypto_key.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/fs/ext4/crypto_key.c b/fs/ext4/crypto_key.c
index 9bad113..dde261b 100644
--- a/fs/ext4/crypto_key.c
+++ b/fs/ext4/crypto_key.c
@@ -230,6 +230,8 @@ retry:
}
res = ext4_derive_key_aes(ctx.nonce, master_key->raw,
raw_key);
+ if (res)
+ goto out;
got_key:
ctfm = crypto_alloc_ablkcipher(cipher_str, 0, 0);
if (!ctfm || IS_ERR(ctfm)) {
--
1.9.1
More information about the kernel-team
mailing list