[3.13.y-ckt stable] Patch "eCryptfs: Remove buggy and unnecessary write in file name decode routine" has been added to staging queue
Kamal Mostafa
kamal at canonical.com
Wed Jan 28 22:19:55 UTC 2015
This is a note to let you know that I have just added a patch titled
eCryptfs: Remove buggy and unnecessary write in file name decode routine
to the linux-3.13.y-queue branch of the 3.13.y-ckt extended stable tree
which can be found at:
http://kernel.ubuntu.com/git?p=ubuntu/linux.git;a=shortlog;h=refs/heads/linux-3.13.y-queue
This patch is scheduled to be released in version 3.13.11-ckt15.
If you, or anyone else, feels it should not be added to this tree, please
reply to this email.
For more information about the 3.13.y-ckt tree, see
https://wiki.ubuntu.com/Kernel/Dev/ExtendedStable
Thanks.
-Kamal
------
>From 93a3ea1148dfcb90951ef61120aacf12b869fdfb Mon Sep 17 00:00:00 2001
From: Michael Halcrow <mhalcrow at google.com>
Date: Wed, 26 Nov 2014 09:09:16 -0800
Subject: eCryptfs: Remove buggy and unnecessary write in file name decode
routine
commit 942080643bce061c3dd9d5718d3b745dcb39a8bc upstream.
Dmitry Chernenkov used KASAN to discover that eCryptfs writes past the
end of the allocated buffer during encrypted filename decoding. This
fix corrects the issue by getting rid of the unnecessary 0 write when
the current bit offset is 2.
Signed-off-by: Michael Halcrow <mhalcrow at google.com>
Reported-by: Dmitry Chernenkov <dmitryc at google.com>
Suggested-by: Kees Cook <keescook at chromium.org>
Signed-off-by: Tyler Hicks <tyhicks at canonical.com>
Signed-off-by: Kamal Mostafa <kamal at canonical.com>
---
fs/ecryptfs/crypto.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/fs/ecryptfs/crypto.c b/fs/ecryptfs/crypto.c
index 2f6735d..31b148f 100644
--- a/fs/ecryptfs/crypto.c
+++ b/fs/ecryptfs/crypto.c
@@ -1917,7 +1917,6 @@ ecryptfs_decode_from_filename(unsigned char *dst, size_t *dst_size,
break;
case 2:
dst[dst_byte_offset++] |= (src_byte);
- dst[dst_byte_offset] = 0;
current_bit_offset = 0;
break;
}
--
1.9.1
More information about the kernel-team
mailing list