aboutsummaryrefslogtreecommitdiffstats
path: root/community/zutils/CVE-2018-1000637.patch
diff options
context:
space:
mode:
authorNatanael Copa <ncopa@alpinelinux.org>2018-08-23 12:48:48 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2018-08-23 12:48:48 +0000
commitd031b70d32b89d1ced1b1d2a15195c0720915d5f (patch)
tree2508f133a67d9a6060fca42b81dbb4480e3a2e01 /community/zutils/CVE-2018-1000637.patch
parent1db02dd10f6540d325d5a754f39133d0560e5110 (diff)
downloadaports-d031b70d32b89d1ced1b1d2a15195c0720915d5f.tar.gz
aports-d031b70d32b89d1ced1b1d2a15195c0720915d5f.tar.bz2
aports-d031b70d32b89d1ced1b1d2a15195c0720915d5f.tar.xz
community/zutils: security fix (CVE-2018-1000637)
fixes #9332
Diffstat (limited to 'community/zutils/CVE-2018-1000637.patch')
-rw-r--r--community/zutils/CVE-2018-1000637.patch17
1 files changed, 17 insertions, 0 deletions
diff --git a/community/zutils/CVE-2018-1000637.patch b/community/zutils/CVE-2018-1000637.patch
new file mode 100644
index 0000000000..8ddc02d5c2
--- /dev/null
+++ b/community/zutils/CVE-2018-1000637.patch
@@ -0,0 +1,17 @@
+--- zutils-1.7/zcat.cc 2018-02-13 19:10:41.000000000 +0000
++++ zutils-1.8-pre2/zcat.cc 2018-07-31 21:49:02.000000000 +0000
+@@ -227,10 +230,11 @@
+ const Cat_options & cat_options )
+ {
+ enum { buffer_size = 4096 };
+- // buffer with space for sentinel newline at the end
++ // buffer with space for sentinel newline at the end
+ uint8_t * const inbuf = new uint8_t[buffer_size+1];
+- // buffer with space for character quoting and 255-digit line number
+- uint8_t * const outbuf = new uint8_t[(4*buffer_size)+256];
++ // buffer with space for character quoting, 255-digit line number and
++ // worst case flushing respect to inbuf.
++ uint8_t * const outbuf = new uint8_t[(5*buffer_size)+256];
+ int retval = 0;
+ Children children;
+ if( !set_data_feeder( input_filename, &infd, children, format_index ) )