b2sum: fix UAR with --check with malformed checksum lines
commite8858f15150e9132355437d3e6aba86fbedeb40a
authorPádraig Brady <P@draigBrady.com>
Thu, 22 Jun 2023 20:33:58 +0000 (22 21:33 +0100)
committerPádraig Brady <P@draigBrady.com>
Thu, 22 Jun 2023 22:22:07 +0000 (22 23:22 +0100)
treea87352d41a1440a8fc7f0ef28f0667a0f02002aa
parented9d8b873065a28659c796eb6068d00fd50e8a26
b2sum: fix UAR with --check with malformed checksum lines

* src/digest.c (split_3): Reinstate the check for whitespace after the
digest portion of the line, so that we exit early before inspecting
the file name which would be outside the passed buffer in the case
where the input does not contain a newline.
* tests/cksum/b2sum.sh: Add a test case.
* NEWS: Mention the bug fix.
* THANKS.in: Add Frank Busse who has reported multiple bugs using KLEE.
Fixes https://bugs.gnu.org/64229
NEWS
THANKS.in
src/digest.c
tests/cksum/b2sum.sh