fix CVE-2022-26280
(cherry picked from commit 211f12ff0d59610d877e35df403a26782b28c296)
This commit is contained in:
parent
5aef6a179f
commit
efbbaa7d87
28
backport-CVE-2022-26280.patch
Normal file
28
backport-CVE-2022-26280.patch
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
From cfaa28168a07ea4a53276b63068f94fce37d6aff Mon Sep 17 00:00:00 2001
|
||||||
|
From: Tim Kientzle <kientzle@acm.org>
|
||||||
|
Date: Thu, 24 Mar 2022 10:35:00 +0100
|
||||||
|
Subject: [PATCH] ZIP reader: fix possible out-of-bounds read in
|
||||||
|
zipx_lzma_alone_init()
|
||||||
|
|
||||||
|
Fixes #1672
|
||||||
|
|
||||||
|
Conflict:NA
|
||||||
|
Reference:https://github.com/libarchive/libarchive/commit/cfaa28168a07ea4a53276b63068f94fce37d6aff
|
||||||
|
---
|
||||||
|
libarchive/archive_read_support_format_zip.c | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/libarchive/archive_read_support_format_zip.c b/libarchive/archive_read_support_format_zip.c
|
||||||
|
index 38ada70b5..9d6c900b2 100644
|
||||||
|
--- a/libarchive/archive_read_support_format_zip.c
|
||||||
|
+++ b/libarchive/archive_read_support_format_zip.c
|
||||||
|
@@ -1667,7 +1667,7 @@ zipx_lzma_alone_init(struct archive_read *a, struct zip *zip)
|
||||||
|
*/
|
||||||
|
|
||||||
|
/* Read magic1,magic2,lzma_params from the ZIPX stream. */
|
||||||
|
- if((p = __archive_read_ahead(a, 9, NULL)) == NULL) {
|
||||||
|
+ if(zip->entry_bytes_remaining < 9 || (p = __archive_read_ahead(a, 9, NULL)) == NULL) {
|
||||||
|
archive_set_error(&a->archive, ARCHIVE_ERRNO_FILE_FORMAT,
|
||||||
|
"Truncated lzma data");
|
||||||
|
return (ARCHIVE_FATAL);
|
||||||
|
|
||||||
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
Name: libarchive
|
Name: libarchive
|
||||||
Version: 3.4.3
|
Version: 3.4.3
|
||||||
Release: 4
|
Release: 5
|
||||||
Summary: Multi-format archive and compression library
|
Summary: Multi-format archive and compression library
|
||||||
|
|
||||||
License: BSD
|
License: BSD
|
||||||
@ -26,6 +26,7 @@ Patch6006: backport-0001-CVE-2021-31566.patch
|
|||||||
Patch6007: backport-0002-CVE-2021-31566.patch
|
Patch6007: backport-0002-CVE-2021-31566.patch
|
||||||
Patch6008: backport-0003-CVE-2021-31566.patch
|
Patch6008: backport-0003-CVE-2021-31566.patch
|
||||||
Patch6009: backport-0004-CVE-2021-31566.patch
|
Patch6009: backport-0004-CVE-2021-31566.patch
|
||||||
|
Patch6010: backport-CVE-2022-26280.patch
|
||||||
|
|
||||||
%description
|
%description
|
||||||
%{name} is an open-source BSD-licensed C programming library that
|
%{name} is an open-source BSD-licensed C programming library that
|
||||||
@ -157,6 +158,9 @@ run_testsuite
|
|||||||
%{_mandir}/man5/*
|
%{_mandir}/man5/*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Jul 04 2022 wangkeorng <wangkerong@partners.com> - 3.4.3-5
|
||||||
|
- fix CVE-2022-26280
|
||||||
|
|
||||||
* Wed Jan 12 2022 yangcheng <yangcheng87@huawei.com> - 3.4.3-4
|
* Wed Jan 12 2022 yangcheng <yangcheng87@huawei.com> - 3.4.3-4
|
||||||
- Type:CVE
|
- Type:CVE
|
||||||
- ID:CVE-2021-23177,CVE-2021-31566
|
- ID:CVE-2021-23177,CVE-2021-31566
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user