xz/src/liblzma
Lasse Collin 1c9a5786d2 liblzma: Make Block decoder catch certain types of errors better.
Now it limits the input and output buffer sizes that are
passed to a raw decoder. This way there's no need to check
if the sizes can grow too big or overflow when updating
Compressed Size and Uncompressed Size counts. This also means
that a corrupt file cannot cause the raw decoder to process
useless extra input or output that would exceed the size info
in Block Header (and thus cause LZMA_DATA_ERROR anyway).

More importantly, now the size information is verified more
carefully in case raw decoder returns LZMA_OK. This doesn't
really matter with the current single-threaded .xz decoder
as the errors would be detected slightly later anyway. But
this helps avoiding corner cases in the upcoming threaded
decompressor, and it might help other Block decoder uses
outside liblzma too.

The test files bad-1-lzma2-{9,10,11}.xz test these conditions.
With the single-threaded .xz decoder the only difference is
that LZMA_DATA_ERROR is detected in a difference place now.
2022-02-20 20:36:27 +02:00
..
api Bump the version number for 5.3.2alpha. 2021-10-28 23:02:11 +03:00
check liblzma: Enable Intel CET in x86 CRC assembly codes 2020-12-23 17:13:33 +02:00
common liblzma: Make Block decoder catch certain types of errors better. 2022-02-20 20:36:27 +02:00
delta liblzma: Fix warnings from -Wsign-conversion. 2019-06-23 21:38:56 +03:00
lz liblzma: Add rough support for output-size-limited encoding in LZMA1. 2021-01-14 18:58:13 +02:00
lzma liblzma: Add NULL checks to LZMA and LZMA2 properties encoders. 2022-02-07 00:20:01 +02:00
rangecoder liblzma: Fix uint64_t vs. size_t confusion. 2022-02-06 23:19:32 +02:00
simple Rename unaligned_read32ne to read32ne, and similarly for the others. 2019-12-31 00:47:49 +02:00
Makefile.am Bump version to 5.3.0alpha and soname to 5.3.99. 2015-03-30 22:44:02 +03:00
liblzma.map Bump the version number for 5.3.2alpha. 2021-10-28 23:02:11 +03:00
liblzma.pc.in liblzma: Fix Libs.private in liblzma.pc to include -lrt when needed. 2012-04-19 14:02:25 +03:00
liblzma_w32res.rc Added public domain notice into a few files. 2009-07-18 11:26:39 +03:00
validate_map.sh liblzma: Use symbol versioning. 2011-05-28 15:55:39 +03:00