diff --git a/meta-oe/recipes-support/imagemagick/files/CVE-2026-23874.patch b/meta-oe/recipes-support/imagemagick/files/CVE-2026-23874.patch new file mode 100644 index 0000000000..1700f6c06a --- /dev/null +++ b/meta-oe/recipes-support/imagemagick/files/CVE-2026-23874.patch @@ -0,0 +1,36 @@ +From 2a09644b10a5b146e0a7c63b778bd74a112ebec3 Mon Sep 17 00:00:00 2001 +From: Cristy +Date: Thu, 15 Jan 2026 17:50:19 -0500 + +Subject: [PATCH] imagemagick: Fix CVE-2026-23874 +CVE: CVE-2026-23874 +Upstream-Status: Backport [https://github.com/ImageMagick/ImageMagick/commit/2a09644b10a5b146e0a7c63b778bd74a112ebec3] +Signed-off-by: Nitin Wankhade +=== +diff --git a/coders/msl.c b/coders/msl.c +index 0e8f632..7ace1b3 100644 +--- a/coders/msl.c ++++ b/coders/msl.c +@@ -7416,9 +7416,19 @@ static void MSLStartElement(void *context,const xmlChar *tag, + + /* process */ + { +- *msl_info->image_info[n]->magick='\0'; +- (void) WriteImage(msl_info->image_info[n], msl_info->image[n], +- msl_info->exception); ++ (void) CopyMagickString(msl_info->image_info[n]->filename, ++ msl_info->image[n]->filename,MagickPathExtent); ++ (void) SetImageInfo(msl_info->image_info[n],1,exception); ++ if (LocaleCompare(msl_info->image_info[n]->magick,"msl") != 0) ++ { ++ *msl_info->image_info[n]->magick='\0'; ++ (void) WriteImage(msl_info->image_info[n],msl_info->image[n], ++ msl_info->exception); ++ } ++ else ++ (void) ThrowMagickException(msl_info->exception,GetMagickModule(), ++ FileOpenError,"UnableToWriteFile","`%s'", ++ msl_info->image[n]->filename); + break; + } + } diff --git a/meta-oe/recipes-support/imagemagick/imagemagick_7.0.10.bb b/meta-oe/recipes-support/imagemagick/imagemagick_7.0.10.bb index e235b9eb89..a2e08afc1a 100644 --- a/meta-oe/recipes-support/imagemagick/imagemagick_7.0.10.bb +++ b/meta-oe/recipes-support/imagemagick/imagemagick_7.0.10.bb @@ -52,6 +52,7 @@ SRC_URI = "git://github.com/ImageMagick/ImageMagick.git;branch=main;protocol=htt file://CVE-2025-66628.patch \ file://CVE-2025-68618.patch \ file://CVE-2026-22770.patch \ + file://CVE-2026-23874.patch \ " SRCREV = "35b4991eb0939a327f3489988c366e21068b0178"