PR #23658 opened by michaelni
URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/23658
Patch URL: https://code.ffmpeg.org/FFmpeg/FFmpeg/pulls/23658.patch
Fixes: heap buffer overflow
Fixes: CRufFb6TVikL
Fixes: dee7440531 (vf_boxblur: Templatize blur{8,16})
Found-by: Pavel Kohout (Aisle Research)
Signed-off-by: Michael Niedermayer <[email protected]>
>From 530ed8f5b377c395ec6b0cbc393bd9574465689b Mon Sep 17 00:00:00 2001
From: Pavel Kohout <[email protected]>
Date: Mon, 29 Jun 2026 23:37:16 +0200
Subject: [PATCH] avfilter/boxblur: reject pixel formats deeper than 16 bits
Fixes: heap buffer overflow
Fixes: CRufFb6TVikL
Fixes: dee7440531 (vf_boxblur: Templatize blur{8,16})
Found-by: Pavel Kohout (Aisle Research)
Signed-off-by: Michael Niedermayer <[email protected]>
---
libavfilter/vf_boxblur.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/libavfilter/vf_boxblur.c b/libavfilter/vf_boxblur.c
index 3cb42471a7..bd5166095f 100644
--- a/libavfilter/vf_boxblur.c
+++ b/libavfilter/vf_boxblur.c
@@ -66,6 +66,7 @@ static int query_formats(const AVFilterContext *ctx,
const AVPixFmtDescriptor *desc = av_pix_fmt_desc_get(fmt);
if (!(desc->flags & (AV_PIX_FMT_FLAG_HWACCEL |
AV_PIX_FMT_FLAG_BITSTREAM | AV_PIX_FMT_FLAG_PAL)) &&
(desc->flags & AV_PIX_FMT_FLAG_PLANAR || desc->nb_components == 1)
&&
+ !(desc->flags & AV_PIX_FMT_FLAG_FLOAT) && desc->comp[0].depth <=
16 &&
(!(desc->flags & AV_PIX_FMT_FLAG_BE) == !HAVE_BIGENDIAN ||
desc->comp[0].depth == 8) &&
(ret = ff_add_format(&formats, fmt)) < 0)
return ret;
--
2.52.0
_______________________________________________
ffmpeg-devel mailing list -- [email protected]
To unsubscribe send an email to [email protected]