summaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended
diff options
context:
space:
mode:
authorPeter Marko <peter.marko@siemens.com>2025-10-08 00:11:41 +0200
committerSteve Sakoman <steve@sakoman.com>2025-10-14 07:20:35 -0700
commit093e91d1906c468497835c9f2e6925ae87f6601d (patch)
tree9805c4f11ec4b81745b1e7f02ea6d9313a7e8288 /meta/recipes-extended
parent0163ca382a7a7dcf56d8dda8f1a66d23e9b0bee3 (diff)
downloadpoky-093e91d1906c468497835c9f2e6925ae87f6601d.tar.gz
ghostscript: patch CVE-2025-59799
Pick commit mentioned in the NVD report. (From OE-Core rev: 10a51275bb0f62b018a6182953352ecf7aa3d220) Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
Diffstat (limited to 'meta/recipes-extended')
-rw-r--r--meta/recipes-extended/ghostscript/ghostscript/CVE-2025-59799.patch41
-rw-r--r--meta/recipes-extended/ghostscript/ghostscript_9.55.0.bb1
2 files changed, 42 insertions, 0 deletions
diff --git a/meta/recipes-extended/ghostscript/ghostscript/CVE-2025-59799.patch b/meta/recipes-extended/ghostscript/ghostscript/CVE-2025-59799.patch
new file mode 100644
index 0000000000..3badd82f22
--- /dev/null
+++ b/meta/recipes-extended/ghostscript/ghostscript/CVE-2025-59799.patch
@@ -0,0 +1,41 @@
1From 6dab38fb211f15226c242ab7a83fa53e4b0ff781 Mon Sep 17 00:00:00 2001
2From: Piotr Kajda <petermasterperfect@gmail.com>
3Date: Thu, 8 May 2025 11:37:09 +0100
4Subject: [PATCH] pdfwrite - bounds check some strings
5
6Bug #708517
7
8This differs very slightly from the proposed patch in the bug report, I
9had a quick scout through the C file and found another similar case.
10
11Both fixed here.
12
13CVE: CVE-2025-59799
14Upstream-Status: Backport [https://github.com/ArtifexSoftware/ghostpdl/commit/6dab38fb211f15226c242ab7a83fa53e4b0ff781]
15Signed-off-by: Peter Marko <peter.marko@siemens.com>
16---
17 devices/vector/gdevpdfm.c | 4 ++++
18 1 file changed, 4 insertions(+)
19
20diff --git a/devices/vector/gdevpdfm.c b/devices/vector/gdevpdfm.c
21index 5aa3644e2..4b1d7d89c 100644
22--- a/devices/vector/gdevpdfm.c
23+++ b/devices/vector/gdevpdfm.c
24@@ -199,6 +199,8 @@ pdfmark_coerce_dest(gs_param_string *dstr, char dest[MAX_DEST_STRING])
25 {
26 const byte *data = dstr->data;
27 uint size = dstr->size;
28+ if (size > MAX_DEST_STRING)
29+ return_error(gs_error_limitcheck);
30 if (size == 0 || data[0] != '(')
31 return 0;
32 /****** HANDLE ESCAPES ******/
33@@ -848,6 +850,8 @@ pdfmark_put_ao_pairs(gx_device_pdf * pdev, cos_dict_t *pcd,
34 char buf[30];
35 int d0, d1;
36
37+ if (Action[1].size > 29)
38+ return_error(gs_error_rangecheck);
39 memcpy(buf, Action[1].data, Action[1].size);
40 buf[Action[1].size] = 0;
41 if (sscanf(buf, "%d %d R", &d0, &d1) == 2)
diff --git a/meta/recipes-extended/ghostscript/ghostscript_9.55.0.bb b/meta/recipes-extended/ghostscript/ghostscript_9.55.0.bb
index c9fcaa7a16..349c007e94 100644
--- a/meta/recipes-extended/ghostscript/ghostscript_9.55.0.bb
+++ b/meta/recipes-extended/ghostscript/ghostscript_9.55.0.bb
@@ -77,6 +77,7 @@ SRC_URI_BASE = "https://github.com/ArtifexSoftware/ghostpdl-downloads/releases/d
77 file://CVE-2025-27836-2.patch \ 77 file://CVE-2025-27836-2.patch \
78 file://CVE-2025-48708.patch \ 78 file://CVE-2025-48708.patch \
79 file://CVE-2025-59798.patch \ 79 file://CVE-2025-59798.patch \
80 file://CVE-2025-59799.patch \
80" 81"
81 82
82SRC_URI = "${SRC_URI_BASE} \ 83SRC_URI = "${SRC_URI_BASE} \