提交 255a7b42 编写于 作者: M Michael Niedermayer

oavformat/avidec: Check offset in odml

Fixes: signed integer overflow: 9223372036854775807 + 8 cannot be represented in type 'long'
Fixes: 38787/clusterfuzz-testcase-minimized-ffmpeg_dem_AVI_fuzzer-4859845799444480

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpegSigned-off-by: NMichael Niedermayer <michael@niedermayer.cc>
上级 83b2e4c8
......@@ -244,7 +244,7 @@ static int read_odml_index(AVFormatContext *s, int64_t frame_num)
avio_rl32(pb); /* size */
duration = avio_rl32(pb);
if (avio_feof(pb))
if (avio_feof(pb) || offset > INT64_MAX - 8)
return AVERROR_INVALIDDATA;
pos = avio_tell(pb);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册