diff options
Diffstat (limited to 'meta-oe/recipes-extended/p7zip/files/CVE-2017-17969.patch')
-rw-r--r-- | meta-oe/recipes-extended/p7zip/files/CVE-2017-17969.patch | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/meta-oe/recipes-extended/p7zip/files/CVE-2017-17969.patch b/meta-oe/recipes-extended/p7zip/files/CVE-2017-17969.patch deleted file mode 100644 index 9ba1078071..0000000000 --- a/meta-oe/recipes-extended/p7zip/files/CVE-2017-17969.patch +++ /dev/null | |||
@@ -1,40 +0,0 @@ | |||
1 | From 7f2da4f810b429ddb7afa0e252e3d02ced0eba87 Mon Sep 17 00:00:00 2001 | ||
2 | From: Radovan Scasny <radovan.scasny@siemens.com> | ||
3 | Date: Tue, 20 Feb 2018 12:08:13 +0100 | ||
4 | Subject: [PATCH] p7zip: Fix CVE-2017-17969 | ||
5 | |||
6 | [No upstream tracking] -- https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=888297 | ||
7 | |||
8 | Heap-based buffer overflow in 7zip | ||
9 | |||
10 | Compress/ShrinkDecoder.cpp: Heap-based buffer overflow | ||
11 | in the NCompress::NShrink::CDecoder::CodeReal method | ||
12 | in 7-Zip before 18.00 and p7zip allows remote attackers | ||
13 | to cause a denial of service (out-of-bounds write) | ||
14 | or potentially execute arbitrary code via a crafted ZIP archive. | ||
15 | |||
16 | Upstream-Status: Backport [https://sourceforge.net/p/p7zip/bugs/_discuss/thread/0920f369/8316/attachment/CVE-2017-17969.patch] | ||
17 | CVE: CVE-2017-17969 | ||
18 | Signed-off-by: Radovan Scasny <radovan.scasny@siemens.com> | ||
19 | |||
20 | --- | ||
21 | CPP/7zip/Compress/ShrinkDecoder.cpp | 5 +++++ | ||
22 | 1 file changed, 5 insertions(+) | ||
23 | |||
24 | diff --git a/CPP/7zip/Compress/ShrinkDecoder.cpp b/CPP/7zip/Compress/ShrinkDecoder.cpp | ||
25 | index 80b7e67..5bb0559 100644 | ||
26 | --- a/CPP/7zip/Compress/ShrinkDecoder.cpp | ||
27 | +++ b/CPP/7zip/Compress/ShrinkDecoder.cpp | ||
28 | @@ -121,7 +121,12 @@ HRESULT CDecoder::CodeReal(ISequentialInStream *inStream, ISequentialOutStream * | ||
29 | { | ||
30 | _stack[i++] = _suffixes[cur]; | ||
31 | cur = _parents[cur]; | ||
32 | + if (cur >= kNumItems || i >= kNumItems) | ||
33 | + break; | ||
34 | } | ||
35 | + | ||
36 | + if (cur >= kNumItems || i >= kNumItems) | ||
37 | + break; | ||
38 | |||
39 | _stack[i++] = (Byte)cur; | ||
40 | lastChar2 = (Byte)cur; | ||