[BZ#2839] Divide by zero in raw2tiff.c
Submitted by Ridwan Shariffdeen (rshariffdeen at gmail dot com) on 2019-01-23 02:10
Description
stacktrace
On 4.0.9, with -fsanitize=undefined:
raw2tiff $FILE out.tiff
Image width and height are not specified.
raw2tiff.c:568:29: runtime error: division by zero
read error.
PoC:
https://github.com/rshariffdeen/poc/blob/master/0001-libtiff-dividebyzero-rawtiff
Patch 889, "proposed fix for raw2tiff.c":
bug2839_proposed_fix-patch-raw2tiff.c