mirror of
https://github.com/xenia-project/FFmpeg.git
synced 2024-11-28 05:50:43 +00:00
check std tag size before reading.
Fixes out of array read Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
a7ee6281f7
commit
b90e795f73
@ -134,6 +134,10 @@ static int fourxm_read_header(AVFormatContext *s)
|
||||
}
|
||||
|
||||
if (fourcc_tag == std__TAG) {
|
||||
if (header_size < i + 16) {
|
||||
av_log(s, AV_LOG_ERROR, "std TAG truncated\n");
|
||||
return AVERROR_INVALIDDATA;
|
||||
}
|
||||
fourxm->fps = av_int2float(AV_RL32(&header[i + 12]));
|
||||
} else if (fourcc_tag == vtrk_TAG) {
|
||||
/* check that there is enough data */
|
||||
|
Loading…
Reference in New Issue
Block a user