Closed kcgen closed 2 years ago
There's nothing to fix here. If the header's size is invalid (i.e. random junk), the seek forward will fail due to it overflowing the size of the file. There's nothing practical to use as a bound check here because a chunk can be any size. Setting this one to wontfix.
Thanks for the explanation. I've marked it as a false-positive and won'tfix - thanks for the quick assessment @mackron !
_"An attacker could control the number of times the loop iterates. In
drwav__read_fmt
, an unscrutinized value from an untrusted source used as a loop bound (CWE-606)"_