summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSona Sarmadi <sona.sarmadi@enea.com>2016-01-05 13:33:13 +0100
committerTudor Florea <tudor.florea@enea.com>2016-01-05 15:37:08 +0100
commit6ba834ef50e5bd7debb89528cd129e5d0818e23c (patch)
tree159174119234f5a2c21a8087066e5a77a4b0ee6c
parent1379026b984e169a3bb8745b09f1000cae2d9535 (diff)
downloadmeta-enea-6ba834ef50e5bd7debb89528cd129e5d0818e23c.tar.gz
kernel-rds: CVE-2015-2042
Fixes information handling flaw in rds sysctl files. Reference: https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2015-2042 Upstream fix: https://git.kernel.org/cgit/linux/kernel/git/stable/linux-stable.git/ patch/?id=2a9eb844a4c126b7e975a086f99f35699e88c011 Signed-off-by: Sona Sarmadi <sona.sarmadi@enea.com> Signed-off-by: Tudor Florea <tudor.florea@enea.com>
-rw-r--r--recipes-kernel/linux/files/net-rds-CVE-2015-2042.patch47
-rw-r--r--recipes-kernel/linux/linux-yocto_3.14.bbappend1
2 files changed, 48 insertions, 0 deletions
diff --git a/recipes-kernel/linux/files/net-rds-CVE-2015-2042.patch b/recipes-kernel/linux/files/net-rds-CVE-2015-2042.patch
new file mode 100644
index 0000000..b8c407e
--- /dev/null
+++ b/recipes-kernel/linux/files/net-rds-CVE-2015-2042.patch
@@ -0,0 +1,47 @@
1From 2a9eb844a4c126b7e975a086f99f35699e88c011 Mon Sep 17 00:00:00 2001
2From: Sasha Levin <sasha.levin@oracle.com>
3Subject: net: rds: use correct size for max unacked packets and bytes
4
5commit db27ebb111e9f69efece08e4cb6a34ff980f8896 upstream.
6
7Max unacked packets/bytes is an int while sizeof(long) was used in the
8sysctl table.
9
10This means that when they were getting read we'd also leak kernel memory
11to userspace along with the timeout values.
12
13Fixes CVE-2015-2041.
14Upstream-Status: Backport
15
16Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
17Signed-off-by: David S. Miller <davem@davemloft.net>
18Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
19Signed-off-by: Sona Sarmadi <sona.sarmadi@enea.com>
20---
21 net/rds/sysctl.c | 4 ++--
22 1 file changed, 2 insertions(+), 2 deletions(-)
23
24diff --git a/net/rds/sysctl.c b/net/rds/sysctl.c
25index b5cb2aa..35773ad 100644
26--- a/net/rds/sysctl.c
27+++ b/net/rds/sysctl.c
28@@ -71,14 +71,14 @@ static struct ctl_table rds_sysctl_rds_table[] = {
29 {
30 .procname = "max_unacked_packets",
31 .data = &rds_sysctl_max_unacked_packets,
32- .maxlen = sizeof(unsigned long),
33+ .maxlen = sizeof(int),
34 .mode = 0644,
35 .proc_handler = proc_dointvec,
36 },
37 {
38 .procname = "max_unacked_bytes",
39 .data = &rds_sysctl_max_unacked_bytes,
40- .maxlen = sizeof(unsigned long),
41+ .maxlen = sizeof(int),
42 .mode = 0644,
43 .proc_handler = proc_dointvec,
44 },
45--
46cgit v0.11.2
47
diff --git a/recipes-kernel/linux/linux-yocto_3.14.bbappend b/recipes-kernel/linux/linux-yocto_3.14.bbappend
index 326066a..30d6561 100644
--- a/recipes-kernel/linux/linux-yocto_3.14.bbappend
+++ b/recipes-kernel/linux/linux-yocto_3.14.bbappend
@@ -12,4 +12,5 @@ SRC_URI += "file://HID_CVE_patches/0005-HID-steelseries-validate-output-report-d
12 file://md-CVE-2015-5697.patch \ 12 file://md-CVE-2015-5697.patch \
13 file://vhost-CVE-2015-6252.patch \ 13 file://vhost-CVE-2015-6252.patch \
14 file://ipv4-CVE-2015-1465.patch \ 14 file://ipv4-CVE-2015-1465.patch \
15 file://net-rds-CVE-2015-2042.patch \
15 " 16 "