mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-01-13 21:28:01 +02:00
avformat/matroskadec: Check timescale
Fixes: 3.82046e+18 is outside the range of representable values of type 'unsigned int'
Fixes: 62276/clusterfuzz-testcase-minimized-ffmpeg_dem_WEBM_DASH_MANIFEST_fuzzer-6381436594421760
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit e849eb2343
)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
08dd17f9d1
commit
03e781da07
@ -2740,6 +2740,10 @@ static int matroska_parse_tracks(AVFormatContext *s)
|
||||
track->time_scale);
|
||||
track->time_scale = 1.0;
|
||||
}
|
||||
|
||||
if (matroska->time_scale * track->time_scale > UINT_MAX)
|
||||
return AVERROR_INVALIDDATA;
|
||||
|
||||
avpriv_set_pts_info(st, 64, matroska->time_scale * track->time_scale,
|
||||
1000 * 1000 * 1000); /* 64 bit pts in ns */
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user