History

avcodec/tak: Check remaining bits in ff_tak_decode_frame_header()

Fixes: out of array access Fixes: 45982/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_TAK_fuzzer-6682195323650048

Michael Niedermayer committed 3 years ago

Commit 19b66b81 parent 2632e901 file · +3 −0Browse files

Unified · Split

libavcodec/tak.c+3−0
@@ -175,6 +175,9 @@ int ff_tak_decode_frame_header(AVCodecContext *avctx, GetBitContext *gb, · 174 unmodified lines
175 if (ti->flags & TAK_FRAME_FLAG_HAS_METADATA)175 if (ti->flags & TAK_FRAME_FLAG_HAS_METADATA)
176 return AVERROR_INVALIDDATA;176 return AVERROR_INVALIDDATA;
177 177
178 if (get_bits_left(gb) < 24)
179 return AVERROR_INVALIDDATA;
180
178 skip_bits(gb, 24);181 skip_bits(gb, 24);
179 182
180 return 0;183 return 0;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t