History

avcodec/xan: Add basic input size check

Fixes: Timeout Fixes: 71739/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_XAN_WC3_fuzzer-6170301405134848

Michael Niedermayer committed 2 years ago

Commit 56bef2f1 parent 03050a01 file · +3 −0Browse files

Showing the changes to libavcodec (1 of 1 file). Show all

Unified · Split

libavcodec/xan.c+3−0
@@ -607,6 +607,9 @@ static int xan_decode_frame(AVCodecContext *avctx, AVFrame *frame, · 606 unmodified lines
607607 return AVERROR_INVALIDDATA;
608608 }
609609
610+ if (buf_size < 9)
611+ return AVERROR_INVALIDDATA;
612+
610613 if ((ret = ff_get_buffer(avctx, frame, AV_GET_BUFFER_FLAG_REF)) < 0)
611614 return ret;
612615

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