mirror of
https://git.yoctoproject.org/poky
synced 2026-03-04 14:29:40 +01:00
Ghostscript before 9.21 might allow remote attackers to bypass the SAFER mode protection mechanism and consequently read arbitrary files via the use of the .libfile operator in a crafted postscript document. Use-after-free vulnerability in Ghostscript 9.20 might allow remote attackers to execute arbitrary code via vectors related to a reference leak in .setdevice. Ghostscript before 9.21 might allow remote attackers to bypass the SAFER mode protection mechanism and consequently execute arbitrary code by leveraging type confusion in .initialize_dsc_parser. libjbig2dec.a in Artifex jbig2dec 0.13, as used in MuPDF and Ghostscript, has a NULL pointer dereference in the jbig2_huffman_get function in jbig2_huffman.c. For example, the jbig2dec utility will crash (segmentation fault) when parsing an invalid file. References: https://nvd.nist.gov/vuln/detail/CVE-2016-7977 https://nvd.nist.gov/vuln/detail/CVE-2016-7978 https://nvd.nist.gov/vuln/detail/CVE-2016-7979 https://nvd.nist.gov/vuln/detail/CVE-2017-9216 Upstream patches: http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=8abd22010eb4db0fb1b10e430d5f5d83e015ef70 http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=6f749c0c44e7b9e09737b9f29edf29925a34f0cf http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=875a0095f37626a721c7ff57d606a0f95af03913 http://git.ghostscript.com/?p=ghostpdl.git;a=commitdiff;h=3ebffb1d96ba0cacec23016eccb4047dab365853 (From OE-Core rev: 584dfa2f780d5785aaff01f84fbabc18b3478d76) (From OE-Core rev: 6fed7cd6077c46ad2213226d4675fad9b10ab024) Signed-off-by: Catalin Enache <catalin.enache@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
34 lines
1002 B
Diff
34 lines
1002 B
Diff
From 8abd22010eb4db0fb1b10e430d5f5d83e015ef70 Mon Sep 17 00:00:00 2001
|
|
From: Chris Liddell <chris.liddell@artifex.com>
|
|
Date: Mon, 3 Oct 2016 01:46:28 +0100
|
|
Subject: [PATCH] Bug 697169: Be rigorous with SAFER permissions
|
|
|
|
Once we've opened our input file from the command line, enforce the SAFER
|
|
rules.
|
|
|
|
Upstream-Status: Backport
|
|
CVE: CVE-2016-7977
|
|
|
|
Signed-off-by: Catalin Enache <catalin.enache@windriver.com>
|
|
---
|
|
psi/zfile.c | 3 +++
|
|
1 file changed, 3 insertions(+)
|
|
|
|
diff --git a/psi/zfile.c b/psi/zfile.c
|
|
index b6caea2..2c6c958 100644
|
|
--- a/psi/zfile.c
|
|
+++ b/psi/zfile.c
|
|
@@ -1081,6 +1081,9 @@ lib_file_open(gs_file_path_ptr lib_path, const gs_memory_t *mem, i_ctx_t *i_ctx
|
|
gs_main_instance *minst = get_minst_from_memory(mem);
|
|
int code;
|
|
|
|
+ if (i_ctx_p && starting_arg_file)
|
|
+ i_ctx_p->starting_arg_file = false;
|
|
+
|
|
/* when starting arg files (@ files) iodev_default is not yet set */
|
|
if (iodev == 0)
|
|
iodev = (gx_io_device *)gx_io_device_table[0];
|
|
--
|
|
2.10.2
|
|
|