commit | 6cef1de7403b553ce8f7e790e38531da6529f34f | [log] [tgz] |
---|---|---|
author | Mark Adler <madler@alumni.caltech.edu> | Thu Nov 26 22:52:25 2015 -0800 |
committer | Mark Adler <madler@alumni.caltech.edu> | Thu Nov 26 22:52:25 2015 -0800 |
tree | 10aa1505aa3bf4c35cf8cc5ca69ab926c8276aa9 | |
parent | 8f1b3744e52b2adb6475c3cd7a07ff9331e9c2fa [diff] |
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.