Skip to contentSkip to conversation

gd: security bump to version 2.2.2

PATCH New Gustavo Zacarias 2 participants 2 messages Jun 26, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 gd: security bump to version 2.2.2

Drop upstreamed patches.
Drop autoreconf since it's no longer required.
Patch 0002-no-zlib.patch is no longer required, and is in fact harmful. Update homepage URL.

Fixes:
CVE-2015-8874 - #215 Stack overflow with gdImageFillToBorder CVE-2016-3074 - gd2: handle corrupt images better CVE-2016-5767 - Integer Overflow in gdImagePaletteToTrueColor() resulting in heap overflow

---
 ...tch => 0002-gd_bmp-fix-build-with-uClibc.patch} |   0
 package/gd/0002-no-zlib.patch                      |  51 ---
 package/gd/0004-webp-pre.patch                     |  37 --
 package/gd/0005-webp.patch                         | 418 ---------------------
 package/gd/Config.in                               |   2 +-
 package/gd/gd.hash                                 |   2 +-
 package/gd/gd.mk                                   |   5 +-
 7 files changed, 4 insertions(+), 511 deletions(-)
 rename package/gd/{0003-gd_bmp-fix-build-with-uClibc.patch => 0002-gd_bmp-fix-build-with-uClibc.patch} (100%)
 delete mode 100644 package/gd/0002-no-zlib.patch
 delete mode 100644 package/gd/0004-webp-pre.patch
 delete mode 100644 package/gd/0005-webp.patch
package/gd/0002-gd_bmp-fix-build-with-uClibc.patch renamed from package/gd/0003-gd_bmp-fix-build-with-uClibc.patch +0 -0
similarity index 100%
rename from package/gd/0003-gd_bmp-fix-build-with-uClibc.patch
rename to package/gd/0002-gd_bmp-fix-build-with-uClibc.patch
package/gd/0002-no-zlib.patch deleted +0 -51

51 lines not on this page · raw message

package/gd/0004-webp-pre.patch deleted +0 -37
deleted file mode 100644
index a4bc068..0000000
@@ -1,37 +0,0 @@
-Patch committed upstream
-https://bitbucket.org/libgd/gd-libgd/commits/c7e5dc617c7466c44935cdefbe7e79de319f98ca?at=master
-
-Downloaded from Gentoo
-https://sources.gentoo.org/cgi-bin/viewvc.cgi/gentoo-x86/media-libs/gd/files/gd-2.1.1-webp-pre.patch?revision=1.1&view=markup
-
-Signed-off-by: Bernd Kuhls <[email protected]>
-
----
-https://bugs.gentoo.org/545956
-
-From c7e5dc617c7466c44935cdefbe7e79de319f98ca Mon Sep 17 00:00:00 2001
-From: Pierre Joye <[email protected]>
-Date: Sat, 17 Jan 2015 08:20:17 +0100
-Subject: [PATCH]  fix #111, invalid default quantization
-
----
- src/gd_webp.c | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/src/gd_webp.c b/src/gd_webp.c
-index fae3861..a3ae1ac 100644
---- a/src/gd_webp.c
-+++ b/src/gd_webp.c
-@@ -185,6 +185,9 @@ BGD_DECLARE(void) gdImageWebpCtx (gdImagePtr im, gdIOCtx * outfile, int quantiza
- 		gd_error("gd-webp error: cannot allocate Y buffer");
- 		return;
- 	}
-+	if (quantization == -1) {
-+		quantization = 80;
-+	}
- 	vp8_quality = mapQualityToVP8QP(quantization);
- 
- 	U = Y + width * height;
--- 
-2.3.5
-
package/gd/0005-webp.patch deleted +0 -418

418 lines not on this page · raw message

package/gd/Config.in +1 -1
index e838635..28b0b0f 100644
@@ -8,7 +8,7 @@ config BR2_PACKAGE_GD
 	  useful in World Wide Web applications, where PNG is one of
 	  the formats accepted for inline images by most browsers.
 
-	  http://libgd.bitbucket.org/
+	  https://libgd.github.io/
 
 if BR2_PACKAGE_GD
 
package/gd/gd.hash +1 -1
index 8edbb1a..d08220a 100644
@@ -1,2 +1,2 @@
 # Locally calculated
-sha256	9ada1ed45594abc998ebc942cef12b032fbad672e73efc22bc9ff54f5df2b285	libgd-2.1.1.tar.xz
+sha256	489f756ce07f0c034b1a794f4d34fdb4d829256112cb3c36feb40bb56b79218c	libgd-2.2.2.tar.xz
package/gd/gd.mk +2 -3
index c056241..8de8d15 100644
@@ -4,10 +4,9 @@
 #
 ################################################################################
 
-GD_VERSION = 2.1.1
+GD_VERSION = 2.2.2
 GD_SOURCE = libgd-$(GD_VERSION).tar.xz
-GD_SITE = https://bitbucket.org/libgd/gd-libgd/downloads
-GD_AUTORECONF = YES
+GD_SITE = https://github.com/libgd/libgd/releases/download/gd-$(GD_VERSION)
 GD_INSTALL_STAGING = YES
 GD_LICENSE = GD license
 GD_LICENSE_FILES = COPYING
Signature · 1 line
2.7.3
#1 lore raw

PATCH 1/1 gd: security bump to version 2.2.2

Hello,

Quoted 12 lines · Gustavo Zacarias

Drop upstreamed patches.
Drop autoreconf since it's no longer required.
Patch 0002-no-zlib.patch is no longer required, and is in fact harmful. Update homepage URL.

Fixes:
CVE-2015-8874 - #215 Stack overflow with gdImageFillToBorder CVE-2016-3074 - gd2: handle corrupt images better CVE-2016-5767 - Integer Overflow in gdImagePaletteToTrueColor() resulting in heap overflow

Quoted 13 lines
---
 ...tch => 0002-gd_bmp-fix-build-with-uClibc.patch} |   0
 package/gd/0002-no-zlib.patch                      |  51 ---
 package/gd/0004-webp-pre.patch                     |  37 --
 package/gd/0005-webp.patch                         | 418 ---------------------
 package/gd/Config.in                               |   2 +-
 package/gd/gd.hash                                 |   2 +-
 package/gd/gd.mk                                   |   5 +-
 7 files changed, 4 insertions(+), 511 deletions(-)
 rename package/gd/{0003-gd_bmp-fix-build-with-uClibc.patch => 0002-gd_bmp-fix-build-with-uClibc.patch} (100%)
 delete mode 100644 package/gd/0002-no-zlib.patch
 delete mode 100644 package/gd/0004-webp-pre.patch
 delete mode 100644 package/gd/0005-webp.patch

Applied to master, thanks.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com