]> git.ipfire.org Git - thirdparty/libarchive.git/commit
7zip: Fix out ouf boundary read in ELF detection 2668/head
authorTobias Stoeckmann <tobias@stoeckmann.org>
Thu, 5 Jun 2025 19:38:43 +0000 (21:38 +0200)
committerTobias Stoeckmann <tobias@stoeckmann.org>
Thu, 5 Jun 2025 19:38:43 +0000 (21:38 +0200)
commitc0691458a0644f3d5bc4d1dc6da61766a6a00b81
tree4814ce55ac487fddb261626cb83402f408319bac
parent75ef803092e64587449743cacf2ae6e22a515f70
7zip: Fix out ouf boundary read in ELF detection

Make sure that the string table size is not smaller than 6 (and also
not larger than SIZE_MAX for better 32 bit support).

Such small values would lead to a large loop limit which either leads to
a crash or wrong detection of a ".data" string in possibly uninitialized
memory.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
libarchive/archive_read_support_format_7zip.c