]> git.ipfire.org Git - thirdparty/zlib-ng.git/commit
Fix bug that accepted invalid zlib header when windowBits is zero. 58/head
authorMark Adler <madler@alumni.caltech.edu>
Fri, 27 Nov 2015 06:52:25 +0000 (22:52 -0800)
committerMika Lindqvist <postmaster@raasu.org>
Sun, 13 Dec 2015 08:30:45 +0000 (10:30 +0200)
commit44bad37ef1a142a150da0c3ca86ba87178e8e463
treec4a8a0d0afb94db90f2ad4cf2fb2c04399aaa5c1
parent76a02fa8c312cc9d2bfc4f9d76c31a67e38d9199
Fix bug that accepted invalid zlib header when windowBits is zero.

When windowBits is zero, the size of the sliding window comes from
the zlib header.  The allowed values of the four-bit field are
0..7, but when windowBits is zero, values greater than 7 are
permitted and acted upon, resulting in large, mostly unused memory
allocations.  This fix rejects such invalid zlib headers.
inflate.c