diff options
author | Dan Tran <dantran@microsoft.com> | 2019-09-20 18:46:57 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-10-10 16:52:30 +0100 |
commit | 7d0a5058e604ff7fc1dc3fe547138a2b85f467a1 (patch) | |
tree | dd11efd6370c1f6fcf387c03804411bf475711ae /meta/recipes-devtools/qemu/qemu/CVE-2018-17958.patch | |
parent | 70f57755d7e841748ec9cfccf6698a9f317bee5e (diff) | |
download | poky-7d0a5058e604ff7fc1dc3fe547138a2b85f467a1.tar.gz |
qemu: Fix 4 CVEs
Fixes CVE-2018-18954, CVE-2019-3812, CVE-2019-6778, and CVE-2019-8934.
Also deleted duplicated patch and cleanup.
(From OE-Core rev: e4b6a39bdf1b660233a7145599cd4fc3e971fc8f)
Signed-off-by: Dan Tran <dantran@microsoft.com>
[fixup for thud-next]
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-devtools/qemu/qemu/CVE-2018-17958.patch')
-rw-r--r-- | meta/recipes-devtools/qemu/qemu/CVE-2018-17958.patch | 52 |
1 files changed, 0 insertions, 52 deletions
diff --git a/meta/recipes-devtools/qemu/qemu/CVE-2018-17958.patch b/meta/recipes-devtools/qemu/qemu/CVE-2018-17958.patch deleted file mode 100644 index af40ff275a..0000000000 --- a/meta/recipes-devtools/qemu/qemu/CVE-2018-17958.patch +++ /dev/null | |||
@@ -1,52 +0,0 @@ | |||
1 | From 06e88ca78d056ea4de885e3a1496805179dc47bc Mon Sep 17 00:00:00 2001 | ||
2 | From: Changqing Li <changqing.li@windriver.com> | ||
3 | Date: Mon, 15 Oct 2018 16:33:04 +0800 | ||
4 | Subject: [PATCH] ne2000: fix possible out of bound access in ne2000_receive | ||
5 | |||
6 | In ne2000_receive(), we try to assign size_ to size which converts | ||
7 | from size_t to integer. This will cause troubles when size_ is greater | ||
8 | INT_MAX, this will lead a negative value in size and it can then pass | ||
9 | the check of size < MIN_BUF_SIZE which may lead out of bound access of | ||
10 | for both buf and buf1. | ||
11 | |||
12 | Fixing by converting the type of size to size_t. | ||
13 | |||
14 | CC: address@hidden | ||
15 | Reported-by: Daniel Shapira <address@hidden> | ||
16 | Reviewed-by: Michael S. Tsirkin <address@hidden> | ||
17 | Signed-off-by: Jason Wang <address@hidden> | ||
18 | |||
19 | Upstream-Status: Backport [https://lists.gnu.org/archive/html/qemu-devel/2018-09/msg03273.html] | ||
20 | |||
21 | CVE: CVE-2018-17958 | ||
22 | |||
23 | Signed-off-by: Changqing Li <changqing.li@windriver.com> | ||
24 | --- | ||
25 | hw/net/ne2000.c | 4 ++-- | ||
26 | 1 file changed, 2 insertions(+), 2 deletions(-) | ||
27 | |||
28 | diff --git a/hw/net/ne2000.c b/hw/net/ne2000.c | ||
29 | index 07d79e3..869518e 100644 | ||
30 | --- a/hw/net/ne2000.c | ||
31 | +++ b/hw/net/ne2000.c | ||
32 | @@ -174,7 +174,7 @@ static int ne2000_buffer_full(NE2000State *s) | ||
33 | ssize_t ne2000_receive(NetClientState *nc, const uint8_t *buf, size_t size_) | ||
34 | { | ||
35 | NE2000State *s = qemu_get_nic_opaque(nc); | ||
36 | - int size = size_; | ||
37 | + size_t size = size_; | ||
38 | uint8_t *p; | ||
39 | unsigned int total_len, next, avail, len, index, mcast_idx; | ||
40 | uint8_t buf1[60]; | ||
41 | @@ -182,7 +182,7 @@ ssize_t ne2000_receive(NetClientState *nc, const uint8_t *buf, size_t size_) | ||
42 | { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }; | ||
43 | |||
44 | #if defined(DEBUG_NE2000) | ||
45 | - printf("NE2000: received len=%d\n", size); | ||
46 | + printf("NE2000: received len=%zu\n", size); | ||
47 | #endif | ||
48 | |||
49 | if (s->cmd & E8390_STOP || ne2000_buffer_full(s)) | ||
50 | -- | ||
51 | 2.7.4 | ||
52 | |||