mirror of
https://git.yoctoproject.org/poky
synced 2026-09-17 21:49:32 +02:00
- The commit [881a070194]
fixes CVE-2023-3576
- Hence, renamed the CVE-2023-3618-1.patch to CVE-2023-3576.patch
- Reference: https://security-tracker.debian.org/tracker/CVE-2023-3576
https://security-tracker.debian.org/tracker/CVE-2023-3618
(From OE-Core rev: 56088368bdd22a939b813c7aefd5ba475c6d4021)
Signed-off-by: Vijay Anusuri <vanusuri@mvista.com>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
36 lines
1.1 KiB
Diff
36 lines
1.1 KiB
Diff
From 881a070194783561fd209b7c789a4e75566f7f37 Mon Sep 17 00:00:00 2001
|
|
From: zhailiangliang <zhailiangliang@loongson.cn>
|
|
Date: Tue, 7 Mar 2023 15:02:08 +0800
|
|
Subject: [PATCH] Fix memory leak in tiffcrop.c
|
|
|
|
Upstream-Status: Backport [https://gitlab.com/libtiff/libtiff/-/commit/881a070194783561fd209b7c789a4e75566f7f37]
|
|
CVE: CVE-2023-3576
|
|
Signed-off-by: Hitendra Prajapati <hprajapati@mvista.com>
|
|
Signed-off-by: Vijay Anusuri <vanusuri@mvista.com>
|
|
---
|
|
tools/tiffcrop.c | 7 ++++++-
|
|
1 file changed, 6 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/tools/tiffcrop.c b/tools/tiffcrop.c
|
|
index f14bb0c..7121c7c 100644
|
|
--- a/tools/tiffcrop.c
|
|
+++ b/tools/tiffcrop.c
|
|
@@ -7746,8 +7746,13 @@ createCroppedImage(struct image_data *image, struct crop_mask *crop,
|
|
|
|
read_buff = *read_buff_ptr;
|
|
|
|
+ /* Memory is freed before crop_buff_ptr is overwritten */
|
|
+ if (*crop_buff_ptr != NULL)
|
|
+ {
|
|
+ _TIFFfree(*crop_buff_ptr);
|
|
+ }
|
|
+
|
|
/* process full image, no crop buffer needed */
|
|
- crop_buff = read_buff;
|
|
*crop_buff_ptr = read_buff;
|
|
crop->combined_width = image->width;
|
|
crop->combined_length = image->length;
|
|
--
|
|
2.25.1
|
|
|