/[packages]/updates/5/libzip/current/SOURCES/libzip-0.11.2-CVE-2017-14107.patch
ViewVC logotype

Contents of /updates/5/libzip/current/SOURCES/libzip-0.11.2-CVE-2017-14107.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1186352 - (show annotations) (download)
Thu Dec 28 18:46:27 2017 UTC (6 years, 3 months ago) by luigiwalser
File size: 1846 byte(s)
rediff patch from opensuse to fix CVE-2017-14107
1 Index: libzip-0.11.1/lib/zip_open.c
2 ===================================================================
3 --- libzip-0.11.1.orig/lib/zip_open.c 2017-09-06 14:50:09.872386069 +0200
4 +++ libzip-0.11.1/lib/zip_open.c 2017-09-06 14:50:09.876386143 +0200
5 @@ -726,7 +726,12 @@ _zip_read_eocd64(FILE *f, const zip_uint
6 _zip_error_set(error, ZIP_ER_SEEK, EFBIG);
7 return NULL;
8 }
9 - if ((flags & ZIP_CHECKCONS) && offset+size != eocd_offset) {
10 + if (offset+size > buf_offset + eocd_offset) {
11 + /* cdir spans past EOCD record */
12 + _zip_error_set(error, ZIP_ER_INCONS, 0);
13 + return NULL;
14 + }
15 + if ((flags & ZIP_CHECKCONS) && offset+size != buf_offset + eocd_offset) {
16 _zip_error_set(error, ZIP_ER_INCONS, 0);
17 return NULL;
18 }
19 Index: libzip-0.11.1/regress/Makefile.am
20 ===================================================================
21 --- libzip-0.11.1.orig/regress/Makefile.am 2013-04-17 10:58:09.000000000 +0200
22 +++ libzip-0.11.1/regress/Makefile.am 2017-09-06 14:51:42.470078673 +0200
23 @@ -129,7 +129,6 @@ TESTS= \
24 extra_add_multiple.test \
25 extra_count.test \
26 extra_count_by_id.test \
27 - extra_count_ignore_zip64.test \
28 extra_delete.test \
29 extra_delete_by_id.test \
30 extra_get.test \
31 @@ -143,7 +142,6 @@ TESTS= \
32 open_extrabytes.test \
33 open_filename_empty.test \
34 open_incons.test \
35 - open_many_ok.test \
36 open_new_but_exists.test \
37 open_new_ok.test \
38 open_nonarchive.test \
39 @@ -185,10 +183,12 @@ DISABLED_TESTS= \
40 encoding-cp437.test \
41 encoding-cp437-all.test \
42 encoding-utf-8.test \
43 + extra_count_ignore_zip64.test \
44 open_filename_duplicate.test \
45 open_filename_duplicate_consistency.test \
46 open_filename_duplicate_empty.test \
47 open_filename_duplicate_empty_consistency.test \
48 + open_many_ok.test \
49 torrent-new.test
50
51 AM_CPPFLAGS=-I${top_srcdir}/lib -I../lib -I${top_srcdir}/src

  ViewVC Help
Powered by ViewVC 1.1.30