Browse code

Bug 1967137: Fix freetyp2 CVE-2017-8105 & update requires for Java

Change-Id: I630295c68e663fc515ed097ba2c14ba1712b10b4
Reviewed-on: http://photon-jenkins.eng.vmware.com:8082/4205
Tested-by: gerrit-photon <photon-checkins@vmware.com>
Reviewed-by: Anish Swaminathan <anishs@vmware.com>

harishspqr authored on 2017/11/04 04:38:24
Showing 5 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,23 @@
0
+diff --git a/src/psaux/t1decode.c b/src/psaux/t1decode.c
1
+index af7b465..7dd4513 100644
2
+--- a/src/psaux/t1decode.c
3
+@@ -780,10 +780,19 @@
4
+             /* point without adding any point to the outline    */
5
+             idx = decoder->num_flex_vectors++;
6
+             if ( idx > 0 && idx < 7 )
7
++            {
8
++              /* in malformed fonts it is possible to have other */
9
++              /* opcodes in the middle of a flex (which don't    */
10
++              /* increase `num_flex_vectors'); we thus have to   */
11
++              /* check whether we can add a point                */
12
++              if ( FT_SET_ERROR( t1_builder_check_points( builder, 1 ) ) )
13
++                goto Syntax_Error;
14
++
15
+               t1_builder_add_point( builder,
16
+                                     x,
17
+                                     y,
18
+                                     (FT_Byte)( idx == 3 || idx == 6 ) );
19
++            }
20
+           }
21
+           break;
... ...
@@ -1,7 +1,7 @@
1 1
 Summary:	software font engine.
2 2
 Name:		freetype2
3 3
 Version:	2.7.1
4
-Release:	3%{?dist}
4
+Release:	4%{?dist}
5 5
 License:	BSD/GPL
6 6
 URL:		http://www.freetype.org/
7 7
 Group:		System Environment/Libraries
... ...
@@ -12,6 +12,7 @@ Source0:	http://download.savannah.gnu.org/releases/freetype/freetype-%{version}.
12 12
 Patch0:         CVE-2017-7857-and-CVE-2017-7858.patch
13 13
 Patch1:         CVE-2017-7864.patch
14 14
 Patch2:         CVE-2017-8287.patch
15
+Patch3:         freetype2-CVE-2017-8105.patch
15 16
 BuildRequires:	libtool
16 17
 BuildRequires:	zlib-devel
17 18
 
... ...
@@ -29,6 +30,7 @@ It contains the libraries and header files to create applications
29 29
 %patch0 -p1
30 30
 %patch1 -p1
31 31
 %patch2 -p1
32
+%patch3 -p1
32 33
 
33 34
 %build
34 35
 ./configure \
... ...
@@ -63,6 +65,8 @@ make -k check |& tee %{_specdir}/%{name}-check-log || %{nocheck}
63 63
 %{_libdir}/pkgconfig/*.pc
64 64
 
65 65
 %changelog
66
+*       Fri Nov 03 2017 Harish Udaiya Kumar <hudaiyakumar@vmware.com> 2.7.1-4
67
+-       CVE-2017-8105
66 68
 *       Mon May 15 2017 Priyesh Padmavilasom <ppadmavilasom@vmware.com> 2.7.1-3
67 69
 -       CVE-2017-8287
68 70
 *       Fri Apr 28 2017 Dheeraj Shetty <dheerajs@vmware.com> 2.7.1-2
... ...
@@ -3,7 +3,7 @@
3 3
 Summary:	OpenJDK
4 4
 Name:		openjdk
5 5
 Version:	1.8.0.151
6
-Release:	1%{?dist}
6
+Release:	2%{?dist}
7 7
 License:	GNU GPL
8 8
 URL:		https://openjdk.java.net
9 9
 Group:		Development/Tools
... ...
@@ -20,6 +20,8 @@ BuildRequires:	unzip
20 20
 BuildRequires:  zlib-devel
21 21
 BuildRequires:	ca-certificates
22 22
 BuildRequires:	chkconfig
23
+BuildRequires:  freetype2-devel
24
+Requires:       freetype2
23 25
 Requires:       openjre = %{version}-%{release}
24 26
 Requires:       chkconfig
25 27
 AutoReqProv: 	no
... ...
@@ -229,6 +231,8 @@ rm -rf %{buildroot}/*
229 229
 %{_libdir}/jvm/OpenJDK-%{version}/src.zip
230 230
 
231 231
 %changelog
232
+*       Fri Nov 03 2017 Harish Udaiya Kumar <hudaiyakumar@vmware.com> 1.8.0.151-2
233
+-       Upgrade requires to include freetype2 from photon OS repo
232 234
 *	Thu Oct 19 2017 Harish Udaiya Kumar <hudaiyakumar@vmware.com> 1.8.0.151-1
233 235
 -	Upgraded to version 1.8.0.151
234 236
 *	Thu Sep 14 2017 Harish Udaiya Kumar <hudaiyakumar@vmware.com> 1.8.0.141-2
... ...
@@ -110,8 +110,6 @@ class constants(object):
110 110
         "icu",
111 111
         "harfbuzz",
112 112
         "harfbuzz-devel",
113
-        "freetype2",
114
-        "freetype2-devel",
115 113
         "alsa-lib",
116 114
         "alsa-lib-devel",
117 115
         "xcb-proto",
... ...
@@ -6,8 +6,6 @@ x86_64/alsa-lib-1.0.29-1.x86_64.rpm
6 6
 x86_64/alsa-lib-devel-1.0.29-1.x86_64.rpm
7 7
 x86_64/fontconfig-2.11.1-1.x86_64.rpm
8 8
 x86_64/fontconfig-devel-2.11.1-1.x86_64.rpm
9
-x86_64/freetype2-2.5.5-1.x86_64.rpm
10
-x86_64/freetype2-devel-2.5.5-1.x86_64.rpm
11 9
 x86_64/glib-2.48.2-1.ph1.x86_64.rpm
12 10
 x86_64/glib-devel-2.48.2-1.ph1.x86_64.rpm
13 11
 x86_64/harfbuzz-0.9.40-1.x86_64.rpm