Message ID | 20220501133758.27115-1-michael@niedermayer.cc |
---|---|
State | Accepted |
Commit | 4f9ee4bf43623ff0960d3d8cf2025c2cdb54382a |
Headers | show |
Series | [FFmpeg-devel] avcodec/pixlet: consider minimum plane header in the minimal packet size | expand |
Context | Check | Description |
---|---|---|
yinshiyou/make_loongarch64 | success | Make finished |
yinshiyou/make_fate_loongarch64 | success | Make fate finished |
andriy/make_x86 | success | Make finished |
andriy/make_fate_x86 | success | Make fate finished |
On Sun, May 01, 2022 at 03:37:58PM +0200, Michael Niedermayer wrote: > Fixes: Timeout > Fixes: 46956/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_PIXLET_fuzzer-5698161106092032 > > Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg > Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> > --- > libavcodec/pixlet.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) will apply [...]
diff --git a/libavcodec/pixlet.c b/libavcodec/pixlet.c index 18a6587257..b16dd4aa87 100644 --- a/libavcodec/pixlet.c +++ b/libavcodec/pixlet.c @@ -611,7 +611,7 @@ static int pixlet_decode_frame(AVCodecContext *avctx, AVFrame *p, bytestream2_init(&ctx->gb, avpkt->data, avpkt->size); pktsize = bytestream2_get_be32(&ctx->gb); - if (pktsize <= 44 || pktsize - 4 > bytestream2_get_bytes_left(&ctx->gb)) { + if (pktsize <= 44 + (NB_LEVELS * 8 + 6) * 3 || pktsize - 4 > bytestream2_get_bytes_left(&ctx->gb)) { av_log(avctx, AV_LOG_ERROR, "Invalid packet size %"PRIu32"\n", pktsize); return AVERROR_INVALIDDATA; }
Fixes: Timeout Fixes: 46956/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_PIXLET_fuzzer-5698161106092032 Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> --- libavcodec/pixlet.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)