Fix CVE-2018-12900 for libtiff
Change-Id: Id025b6abf54d0de93a6fd5acafab292efc168d4d
Reviewed-on: http://photon-jenkins.eng.vmware.com:8082/6663
Tested-by: gerrit-photon <photon-checkins@vmware.com>
Reviewed-by: Anish Swaminathan <anishs@vmware.com>
| 1 | 1 |
new file mode 100644 |
| ... | ... |
@@ -0,0 +1,15 @@ |
| 0 |
+--- a/tools/tiffcp.c 2018-11-10 21:03:11.000000000 +0530 |
|
| 1 |
+@@ -1435,6 +1435,12 @@ |
|
| 2 |
+ status = 0; |
|
| 3 |
+ goto done; |
|
| 4 |
+ } |
|
| 5 |
++ if (0xFFFFFFFF / tilew < spp) |
|
| 6 |
++ {
|
|
| 7 |
++ TIFFError(TIFFFileName(in), "Error, either TileWidth (%u) or SamplePerPixel (%u) is too large", tilew, spp); |
|
| 8 |
++ status = 0; |
|
| 9 |
++ goto done; |
|
| 10 |
++ } |
|
| 11 |
+ bytes_per_sample = bps/8; |
|
| 12 |
+ |
|
| 13 |
+ for (row = 0; row < imagelength; row += tl) {
|
| ... | ... |
@@ -1,7 +1,7 @@ |
| 1 | 1 |
Summary: TIFF libraries and associated utilities. |
| 2 | 2 |
Name: libtiff |
| 3 | 3 |
Version: 4.0.10 |
| 4 |
-Release: 1%{?dist}
|
|
| 4 |
+Release: 2%{?dist}
|
|
| 5 | 5 |
License: libtiff |
| 6 | 6 |
URL: http://www.simplesystems.org/libtiff/ |
| 7 | 7 |
Group: System Environment/Libraries |
| ... | ... |
@@ -9,7 +9,7 @@ Vendor: VMware, Inc. |
| 9 | 9 |
Distribution: Photon |
| 10 | 10 |
Source0: https://gitlab.com/libtiff/libtiff/-/archive/v%{version}/libtiff-v%{version}.tar.gz
|
| 11 | 11 |
%define sha1 libtiff-v=e4ec512e56544d7586178dc69c7b5728f74fcc79 |
| 12 |
- |
|
| 12 |
+Patch0: CVE-2018-12900.patch |
|
| 13 | 13 |
BuildRequires: libjpeg-turbo-devel |
| 14 | 14 |
Requires: libjpeg-turbo |
| 15 | 15 |
%description |
| ... | ... |
@@ -24,6 +24,7 @@ It contains the libraries and header files to create applications |
| 24 | 24 |
|
| 25 | 25 |
%prep |
| 26 | 26 |
%setup -q -n libtiff-v%{version}
|
| 27 |
+%patch0 -p1 |
|
| 27 | 28 |
|
| 28 | 29 |
%build |
| 29 | 30 |
sh autogen.sh |
| ... | ... |
@@ -59,6 +60,8 @@ make %{?_smp_mflags} -k check
|
| 59 | 59 |
%{_datadir}/man/man3/*
|
| 60 | 60 |
|
| 61 | 61 |
%changelog |
| 62 |
+* Fri Feb 08 2019 Tapas Kundu <tkundu@vmware.com> 4.0.10-2 |
|
| 63 |
+- Fix for CVE-2018-12900 |
|
| 62 | 64 |
* Thu Dec 27 2018 Ashwin H <ankitja@vmware.com> 4.0.10-1 |
| 63 | 65 |
- Update to 4.0.10 |
| 64 | 66 |
* Mon Nov 19 2018 Ashwin H <ankitja@vmware.com> 4.0.9-7 |