You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-10 06:10:52 +02:00
avformat/mov: check for pts overflow in mov_read_sidx()
Fixes: signed integer overflow: 9223372036846336888 + 4278255871 cannot be represented in type 'long' Fixes: 32782/clusterfuzz-testcase-minimized-ffmpeg_dem_MOV_fuzzer-6059216516284416 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
@@ -5111,7 +5111,9 @@ static int mov_read_sidx(MOVContext *c, AVIOContext *pb, MOVAtom atom)
|
|||||||
if (frag_stream_info)
|
if (frag_stream_info)
|
||||||
frag_stream_info->sidx_pts = timestamp;
|
frag_stream_info->sidx_pts = timestamp;
|
||||||
|
|
||||||
if (av_sat_add64(offset, size) != offset + size)
|
if (av_sat_add64(offset, size) != offset + size ||
|
||||||
|
av_sat_add64(pts, duration) != pts + (uint64_t)duration
|
||||||
|
)
|
||||||
return AVERROR_INVALIDDATA;
|
return AVERROR_INVALIDDATA;
|
||||||
offset += size;
|
offset += size;
|
||||||
pts += duration;
|
pts += duration;
|
||||||
|
Reference in New Issue
Block a user