diff options
author | Dan Tran <dantran@microsoft.com> | 2019-09-25 23:30:12 +0000 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-10-10 16:52:30 +0100 |
commit | b15ffd14acf9008755abc5048792a03953290f21 (patch) | |
tree | bbbc8bb370c057ea728557ee888b4fd9763ee512 /meta/recipes-extended/unzip/unzip/CVE-2019-13232_p1.patch | |
parent | 2d699f84a3002a9c159dab571f14fba79aea5c59 (diff) | |
download | poky-b15ffd14acf9008755abc5048792a03953290f21.tar.gz |
unzip: fix CVE-2019-13232
(From OE-Core rev: 7857d85db69bcb2cb94399a22de6903263e52965)
Signed-off-by: Dan Tran <dantran@microsoft.com>
Signed-off-by: Armin Kuster <akuster808@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-extended/unzip/unzip/CVE-2019-13232_p1.patch')
-rw-r--r-- | meta/recipes-extended/unzip/unzip/CVE-2019-13232_p1.patch | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/meta/recipes-extended/unzip/unzip/CVE-2019-13232_p1.patch b/meta/recipes-extended/unzip/unzip/CVE-2019-13232_p1.patch new file mode 100644 index 0000000000..d485a1bd6e --- /dev/null +++ b/meta/recipes-extended/unzip/unzip/CVE-2019-13232_p1.patch | |||
@@ -0,0 +1,33 @@ | |||
1 | From 080d52c3c9416c731f637f9c6e003961ef43f079 Mon Sep 17 00:00:00 2001 | ||
2 | From: Mark Adler <madler@alumni.caltech.edu> | ||
3 | Date: Mon, 27 May 2019 08:20:32 -0700 | ||
4 | Subject: [PATCH 1/3] Fix bug in undefer_input() that misplaced the input | ||
5 | state. | ||
6 | |||
7 | CVE: CVE-2019-13232 | ||
8 | Upstream-Status: Backport | ||
9 | [https://github.com/madler/unzip/commit/41beb477c5744bc396fa1162ee0c14218ec12213] | ||
10 | |||
11 | Signed-off-by: Dan Tran <dantran@microsoft.com> | ||
12 | --- | ||
13 | fileio.c | 4 +++- | ||
14 | 1 file changed, 3 insertions(+), 1 deletion(-) | ||
15 | |||
16 | diff --git a/fileio.c b/fileio.c | ||
17 | index 7605a29..14460f3 100644 | ||
18 | --- a/fileio.c | ||
19 | +++ b/fileio.c | ||
20 | @@ -532,8 +532,10 @@ void undefer_input(__G) | ||
21 | * This condition was checked when G.incnt_leftover was set > 0 in | ||
22 | * defer_leftover_input(), and it is NOT allowed to touch G.csize | ||
23 | * before calling undefer_input() when (G.incnt_leftover > 0) | ||
24 | - * (single exception: see read_byte()'s "G.csize <= 0" handling) !! | ||
25 | + * (single exception: see readbyte()'s "G.csize <= 0" handling) !! | ||
26 | */ | ||
27 | + if (G.csize < 0L) | ||
28 | + G.csize = 0L; | ||
29 | G.incnt = G.incnt_leftover + (int)G.csize; | ||
30 | G.inptr = G.inptr_leftover - (int)G.csize; | ||
31 | G.incnt_leftover = 0; | ||
32 | -- | ||
33 | 2.22.0.vfs.1.1.57.gbaf16c8 | ||