diff --git a/SOURCES/ImageMagick-bz2005800-sun-raster.patch b/SOURCES/ImageMagick-bz2005800-sun-raster.patch new file mode 100644 index 0000000..93181e8 --- /dev/null +++ b/SOURCES/ImageMagick-bz2005800-sun-raster.patch @@ -0,0 +1,22 @@ +From 9aa42a7ea0c943a6be3e3deb65de785f4890a2cf Mon Sep 17 00:00:00 2001 +From: Cristy +Date: Wed, 9 Dec 2020 01:41:35 +0000 +Subject: [PATCH] https://github.com/ImageMagick/ImageMagick6/issues/117 + +--- + coders/sun.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/coders/sun.c b/coders/sun.c +index 985fe87dfc..e3e1827601 100644 +--- a/coders/sun.c ++++ b/coders/sun.c +@@ -489,7 +489,7 @@ static Image *ReadSUNImage(const ImageInfo *image_info,ExceptionInfo *exception) + } + else + { +- if (sun_info.length > pixels_length) ++ if (sun_info.length > (pixels_length+image->rows)) + { + sun_data=(unsigned char *) RelinquishMagickMemory(sun_data); + sun_pixels=(unsigned char *) RelinquishMagickMemory(sun_pixels); diff --git a/SPECS/ImageMagick.spec b/SPECS/ImageMagick.spec index b3f8028..5a47137 100644 --- a/SPECS/ImageMagick.spec +++ b/SPECS/ImageMagick.spec @@ -3,7 +3,7 @@ Name: ImageMagick Version: %{VER}.%{Patchlevel} -Release: 5%{?dist} +Release: 6%{?dist} Summary: An X application for displaying and manipulating images Group: Applications/Multimedia License: ImageMagick @@ -13,6 +13,7 @@ Source0: ftp://ftp.ImageMagick.org/pub/%{name}/%{name}-%{VER}-%{Patchlevel}.tar Patch4: ImageMagick-cve-2016-5118.patch Patch5: ImageMagick-freeze-svg-empty-class.patch Patch6: ImageMagick-cve-2020-29599.patch +Patch7: ImageMagick-bz2005800-sun-raster.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: bzip2-devel, freetype-devel, libjpeg-devel, libpng-devel @@ -132,6 +133,7 @@ cp -p Magick++/demo/*.cpp Magick++/demo/*.miff Magick++/examples %patch4 -p1 -b .cve-2016-5118 %patch5 -p1 -b .cve-2016-5240 %patch6 -p1 -b .cve-2020-29599 +%patch7 -p1 -b .bz2005800-sun-raster %build %configure --enable-shared \ @@ -301,6 +303,9 @@ rm -rf %{buildroot} %doc PerlMagick/demo/ PerlMagick/Changelog PerlMagick/README.txt %changelog +* Wed Sep 22 2021 Jan Horak - 6.9.10.68-6 +- Added fix for rhbz#2005800 + * Fri Dec 18 2020 Jan Horak - 6.9.10.68-5 - Adding CTV-2020-29599 fix