fix CVE-2022-34526
(cherry picked from commit 798e642bdca737faaed478b366e49793dda75872)
This commit is contained in:
parent
43196d2bb1
commit
c98d93a2d7
31
backport-CVE-2022-34526.patch
Normal file
31
backport-CVE-2022-34526.patch
Normal file
@ -0,0 +1,31 @@
|
||||
From 275735d0354e39c0ac1dc3c0db2120d6f31d1990 Mon Sep 17 00:00:00 2001
|
||||
From: Even Rouault <even.rouault@spatialys.com>
|
||||
Date: Mon, 27 Jun 2022 16:09:43 +0200
|
||||
Subject: [PATCH] _TIFFCheckFieldIsValidForCodec(): return FALSE when passed a
|
||||
codec-specific tag and the codec is not configured (fixes #433)
|
||||
|
||||
This avoids crashes when querying such tags
|
||||
|
||||
Reference:https://gitlab.com/libtiff/libtiff/-/commit/275735d0354e39c0ac1dc3c0db2120d6f31d1990
|
||||
Conflict:NA
|
||||
---
|
||||
libtiff/tif_dirinfo.c | 3 +++
|
||||
1 file changed, 3 insertions(+)
|
||||
|
||||
diff --git a/libtiff/tif_dirinfo.c b/libtiff/tif_dirinfo.c
|
||||
index c30f569b..3371cb5c 100644
|
||||
--- a/libtiff/tif_dirinfo.c
|
||||
+++ b/libtiff/tif_dirinfo.c
|
||||
@@ -1191,6 +1191,9 @@ _TIFFCheckFieldIsValidForCodec(TIFF *tif, ttag_t tag)
|
||||
default:
|
||||
return 1;
|
||||
}
|
||||
+ if( !TIFFIsCODECConfigured(tif->tif_dir.td_compression) ) {
|
||||
+ return 0;
|
||||
+ }
|
||||
/* Check if codec specific tags are allowed for the current
|
||||
* compression scheme (codec) */
|
||||
switch (tif->tif_dir.td_compression) {
|
||||
--
|
||||
GitLab
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
Name: libtiff
|
||||
Version: 4.3.0
|
||||
Release: 32
|
||||
Release: 33
|
||||
Summary: TIFF Library and Utilities
|
||||
License: libtiff
|
||||
URL: https://www.simplesystems.org/libtiff/
|
||||
@ -46,6 +46,7 @@ Patch6036: backport-CVE-2023-38288.patch
|
||||
Patch6037: backport-CVE-2023-38289.patch
|
||||
Patch6038: backport-CVE-2023-3618.patch
|
||||
Patch6039: backport-CVE-2022-40090.patch
|
||||
Patch6040: backport-CVE-2022-34526.patch
|
||||
|
||||
Patch9000: fix-raw2tiff-floating-point-exception.patch
|
||||
|
||||
@ -169,6 +170,9 @@ find html -name 'Makefile*' | xargs rm
|
||||
%exclude %{_datadir}/html/man/tiffgt.1.html
|
||||
|
||||
%changelog
|
||||
* Thu Sep 07 2023 zhangpan <zhangpan103@h-partners.com> - 4.3.0-33
|
||||
- fix CVE-2022-34526
|
||||
|
||||
* Fri Sep 01 2023 zhangpan <zhangpan103@h-partners.com> - 4.3.0-32
|
||||
- fix CVE-2022-40090
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user