]> git.ipfire.org Git - thirdparty/libarchive.git/commit
Fix integer overflow in __archive_read_filter_ahead 3083/head
authorTobias Stoeckmann <tobias@stoeckmann.org>
Wed, 27 May 2026 19:54:42 +0000 (21:54 +0200)
committerTobias Stoeckmann <tobias@stoeckmann.org>
Wed, 27 May 2026 19:54:42 +0000 (21:54 +0200)
commit5fa691b8724f0e6e8868ae380234476a2ef27c22
tree2be2a9f21f4d50e99f0f35d7207a4e7dcdf72702
parentc15997d4f303e01da11cb13e95783866c5cb0687
Fix integer overflow in __archive_read_filter_ahead

The pointer arithmetic could overflow with a large min value. Prevent
this by using subtraction instead of addition.

Resolves #3025.

Co-authored-by: ypp <alen0421@gmail.com>
Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
libarchive/archive_read.c