diff options
author | Efraim Flashner <efraim@flashner.co.il> | 2017-02-03 22:17:41 +0200 |
---|---|---|
committer | Efraim Flashner <efraim@flashner.co.il> | 2017-02-03 22:17:41 +0200 |
commit | 1ac675a5831e39968be3c137a4ff448c9f65f48e (patch) | |
tree | 89433cb9413ffb193ffc134989a271a947f8b01a /gnu/packages/patches | |
parent | b352b57655197d335e4dddcbc837e44a38b646b8 (diff) |
gnu: p7zip: Fix CVE-2016-9256.
* gnu/packages/compression.scm (p7zip)[source]: Add patch.
* gnu/packages/patches/p7zip-CVE-2016-9296.patch: New file.
* gnu/local.mk (dist_patch_DATA): Register it.
Diffstat (limited to 'gnu/packages/patches')
-rw-r--r-- | gnu/packages/patches/p7zip-CVE-2016-9296.patch | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/gnu/packages/patches/p7zip-CVE-2016-9296.patch b/gnu/packages/patches/p7zip-CVE-2016-9296.patch new file mode 100644 index 0000000000..3fa80377ad --- /dev/null +++ b/gnu/packages/patches/p7zip-CVE-2016-9296.patch @@ -0,0 +1,24 @@ +From: Robert Luberda <robert@debian.org> +Date: Sat, 19 Nov 2016 08:48:08 +0100 +Subject: Fix nullptr dereference (CVE-2016-9296) + +Patch taken from https://sourceforge.net/p/p7zip/bugs/185/ +This patch file taken from Debian's patch set for p7zip +--- + CPP/7zip/Archive/7z/7zIn.cpp | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/CPP/7zip/Archive/7z/7zIn.cpp b/CPP/7zip/Archive/7z/7zIn.cpp +index b0c6b98..7c6dde2 100644 +--- a/CPP/7zip/Archive/7z/7zIn.cpp ++++ b/CPP/7zip/Archive/7z/7zIn.cpp +@@ -1097,7 +1097,8 @@ HRESULT CInArchive::ReadAndDecodePackedStreams( + if (CrcCalc(data, unpackSize) != folders.FolderCRCs.Vals[i]) + ThrowIncorrect(); + } +- HeadersSize += folders.PackPositions[folders.NumPackStreams]; ++ if (folders.PackPositions) ++ HeadersSize += folders.PackPositions[folders.NumPackStreams]; + return S_OK; + } + |