[python-imaging] Buffer overflow patch (#703212)

Roman Rakus rrakus at fedoraproject.org
Tue Jun 7 09:58:13 UTC 2011


commit 4800f0f7ef7def0fbfacd7f1fdd2a62796a51892
Author: Roman Rakus <rrakus at redhat.com>
Date:   Tue Jun 7 11:57:49 2011 +0200

    Buffer overflow patch (#703212)
    
    Signed-off-by: Roman Rakus <rrakus at redhat.com>

 python-imaging-buffer.patch |   12 ++++++++++++
 python-imaging.spec         |    9 ++++++++-
 2 files changed, 20 insertions(+), 1 deletions(-)
---
diff --git a/python-imaging-buffer.patch b/python-imaging-buffer.patch
new file mode 100644
index 0000000..246ff0b
--- /dev/null
+++ b/python-imaging-buffer.patch
@@ -0,0 +1,12 @@
+diff -up Imaging-1.1.7/libImaging/Imaging.h.buffer Imaging-1.1.7/libImaging/Imaging.h
+--- Imaging-1.1.7/libImaging/Imaging.h.buffer	2011-06-07 11:44:02.000000000 +0200
++++ Imaging-1.1.7/libImaging/Imaging.h	2011-06-07 11:46:17.000000000 +0200
+@@ -75,7 +75,7 @@ typedef struct ImagingPaletteInstance* I
+ struct ImagingMemoryInstance {
+ 
+     /* Format */
+-    char mode[4+1];	/* Band names ("1", "L", "P", "RGB", "RGBA", "CMYK") */
++    char mode[6+1];	/* Band names ("1", "L", "P", "RGB", "RGBA", "CMYK", "YCbCr", "BGR;xy") */
+     int type;		/* Data type (IMAGING_TYPE_*) */
+     int depth;		/* Depth (ignored in this version) */
+     int bands;		/* Number of bands (1, 2, 3, or 4) */
diff --git a/python-imaging.spec b/python-imaging.spec
index 869f90e..f2d8a39 100644
--- a/python-imaging.spec
+++ b/python-imaging.spec
@@ -5,7 +5,7 @@
 Summary:       Python's own image processing library
 Name:          python-imaging
 Version:       1.1.7
-Release:       3%{?dist}
+Release:       4%{?dist}
 
 License:       MIT
 Group:         System Environment/Libraries
@@ -15,6 +15,9 @@ Patch1:        %{name}-lib64.patch
 Patch2:        %{name}-giftrans.patch
 Patch3:        %{name}-1.1.6-sane-types.patch
 Patch4:        %{name}-shebang.patch
+
+# buffer overflow patch, bz 703212
+Patch5:        %{name}-buffer.patch
 URL:           http://www.pythonware.com/products/pil/
 BuildRoot:     %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
@@ -75,6 +78,7 @@ This package contains a Tk interface for python-imaging.
 %patch2 -p1
 %patch3 -p1 -b .sane-types
 %patch4 -p1 -b .shebang
+%patch5 -p1 -b .buffer
 
 # fix the interpreter path for Scripts/*.py
 cd Scripts
@@ -171,6 +175,9 @@ rm -rf $RPM_BUILD_ROOT
 %files tk -f files.tk
 
 %changelog
+* Tue Jun 07 2011 Roman Rakus <rrakus at redhat.com> - 1.1.7-4
+- Buffer overflow patch (#703212)
+
 * Tue Feb 08 2011 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 1.1.7-3
 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
 


More information about the scm-commits mailing list