From fe8d74b25a99c8a63666ae5f8fab498c953a740e Mon Sep 17 00:00:00 2001 From: Dirk Meyer Date: Sat, 23 Jun 2012 14:52:05 +0000 Subject: - update to 4.0.2 --- graphics/tiff/Makefile | 3 +- graphics/tiff/distinfo | 4 +- graphics/tiff/files/patch-CVE-2012-1173 | 77 --------------------------------- graphics/tiff/pkg-plist | 2 + 4 files changed, 5 insertions(+), 81 deletions(-) delete mode 100644 graphics/tiff/files/patch-CVE-2012-1173 (limited to 'graphics/tiff') diff --git a/graphics/tiff/Makefile b/graphics/tiff/Makefile index 94fd96e22a8c..ba15baa91066 100644 --- a/graphics/tiff/Makefile +++ b/graphics/tiff/Makefile @@ -8,8 +8,7 @@ # PORTNAME= tiff -PORTVERSION= 4.0.1 -PORTREVISION= 1 +PORTVERSION= 4.0.2 CATEGORIES= graphics MASTER_SITES= ftp://ftp.remotesensing.org/pub/libtiff/ \ http://download.osgeo.org/libtiff/ diff --git a/graphics/tiff/distinfo b/graphics/tiff/distinfo index d55f8258be6b..e05dfe115731 100644 --- a/graphics/tiff/distinfo +++ b/graphics/tiff/distinfo @@ -1,2 +1,2 @@ -SHA256 (tiff-4.0.1.tar.gz) = 9a7a039e516c37478038740f1642818250bfb1414cf404cc8b569e5f9d4bf2f0 -SIZE (tiff-4.0.1.tar.gz) = 1991580 +SHA256 (tiff-4.0.2.tar.gz) = aa29f1f5bfe3f443c3eb4dac472ebde15adc8ff0464b83376f35e3b2fef935da +SIZE (tiff-4.0.2.tar.gz) = 2022814 diff --git a/graphics/tiff/files/patch-CVE-2012-1173 b/graphics/tiff/files/patch-CVE-2012-1173 deleted file mode 100644 index 90b4987f7982..000000000000 --- a/graphics/tiff/files/patch-CVE-2012-1173 +++ /dev/null @@ -1,77 +0,0 @@ ---- ChangeLog.orig 2012-02-18 23:02:33.000000000 +0100 -+++ ChangeLog 2012-04-13 06:01:25.000000000 +0200 -@@ -1,4 +1,9 @@ - 2012-02-18 Bob Friesenhahn -+2012-03-30 Frank Warmerdam -+ -+ * tif_getimage.c: Fix size overflow (zdi-can-1221,CVE-2012-1173) -+ care of Tom Lane @ Red Hat. -+ - - * libtiff 4.0.1 released. - ---- libtiff/tif_getimage.c.orig 2011-02-25 04:34:02.000000000 +0100 -+++ libtiff/tif_getimage.c 2012-04-13 06:01:25.000000000 +0200 -@@ -693,18 +693,24 @@ - unsigned char* pa; - tmsize_t tilesize; - int32 fromskew, toskew; -+ tmsize_t bufsize; - int alpha = img->alpha; - uint32 nrow; - int ret = 1, flip; - int colorchannels; - - tilesize = TIFFTileSize(tif); -- buf = (unsigned char*) _TIFFmalloc((alpha?4:3)*tilesize); -+ bufsize = TIFFSafeMultiply(tmsize_t,alpha?4:3,tilesize); -+ if (bufsize == 0) { -+ TIFFErrorExt(tif->tif_clientdata, TIFFFileName(tif), "Integer overflow in %s", "gtTileSeparate"); -+ return (0); -+ } -+ buf = (unsigned char*) _TIFFmalloc(bufsize); - if (buf == 0) { - TIFFErrorExt(tif->tif_clientdata, TIFFFileName(tif), "%s", "No space for tile buffer"); - return (0); - } -- _TIFFmemset(buf, 0, (alpha?4:3)*tilesize); -+ _TIFFmemset(buf, 0, bufsize); - p0 = buf; - p1 = p0 + tilesize; - p2 = p1 + tilesize; -@@ -918,16 +924,22 @@ - uint32 imagewidth = img->width; - tmsize_t stripsize; - int32 fromskew, toskew; -+ tmsize_t bufsize; - int alpha = img->alpha; - int ret = 1, flip, colorchannels; - - stripsize = TIFFStripSize(tif); -- p0 = buf = (unsigned char *)_TIFFmalloc((alpha?4:3)*stripsize); -+ bufsize = TIFFSafeMultiply(tmsize_t,alpha?4:3,stripsize); -+ if (bufsize == 0) { -+ TIFFErrorExt(tif->tif_clientdata, TIFFFileName(tif), "Integer overflow in %s", "gtStripSeparate"); -+ return (0); -+ } -+ p0 = buf = (unsigned char *)_TIFFmalloc(bufsize); - if (buf == 0) { - TIFFErrorExt(tif->tif_clientdata, TIFFFileName(tif), "No space for tile buffer"); - return (0); - } -- _TIFFmemset(buf, 0, (alpha?4:3)*stripsize); -+ _TIFFmemset(buf, 0, bufsize); - p1 = p0 + stripsize; - p2 = p1 + stripsize; - pa = (alpha?(p2+stripsize):NULL); ---- libtiff/tiffiop.h.orig 2011-02-19 17:26:09.000000000 +0100 -+++ libtiff/tiffiop.h 2012-04-13 06:01:25.000000000 +0200 -@@ -250,7 +250,7 @@ - #define TIFFroundup_64(x, y) (TIFFhowmany_64(x,y)*(y)) - - /* Safe multiply which returns zero if there is an integer overflow */ --#define TIFFSafeMultiply(t,v,m) ((((t)m != (t)0) && (((t)((v*m)/m)) == (t)v)) ? (t)(v*m) : (t)0) -+#define TIFFSafeMultiply(t,v,m) ((((t)(m) != (t)0) && (((t)(((v)*(m))/(m))) == (t)(v))) ? (t)((v)*(m)) : (t)0) - - #define TIFFmax(A,B) ((A)>(B)?(A):(B)) - #define TIFFmin(A,B) ((A)<(B)?(A):(B)) diff --git a/graphics/tiff/pkg-plist b/graphics/tiff/pkg-plist index 68d59b12f527..2a12760a9cd0 100644 --- a/graphics/tiff/pkg-plist +++ b/graphics/tiff/pkg-plist @@ -166,6 +166,8 @@ libdata/pkgconfig/libtiff-4.pc %%PORTDOCS%%%%DOCSDIR%%/v3.9.1.html %%PORTDOCS%%%%DOCSDIR%%/v3.9.2.html %%PORTDOCS%%%%DOCSDIR%%/v4.0.0.html +%%PORTDOCS%%%%DOCSDIR%%/v4.0.1.html +%%PORTDOCS%%%%DOCSDIR%%/v4.0.2.html %%PORTDOCS%%@dirrm %%DOCSDIR%%/man %%PORTDOCS%%@dirrm %%DOCSDIR%%/images %%PORTDOCS%%@dirrm %%DOCSDIR%% -- cgit v1.2.3