[FFmpeg-cvslog] [ffmpeg] branch master updated. 0469d68acb avcodec/exr: Check for pixel type consistency in DWA
ffmpeg-git at ffmpeg.org
ffmpeg-git at ffmpeg.org
Tue Aug 12 13:29:15 EEST 2025
The branch, master has been updated
via 0469d68acb52081ca8385b844b9650398242be0f (commit)
from 069201c53561795bc18e55d1e2eb84dc03cf1ed3 (commit)
- Log -----------------------------------------------------------------
commit 0469d68acb52081ca8385b844b9650398242be0f
Author: Michael Niedermayer <michael at niedermayer.cc>
AuthorDate: Sat Aug 9 14:05:19 2025 +0200
Commit: Michael Niedermayer <michael at niedermayer.cc>
CommitDate: Tue Aug 12 12:21:09 2025 +0200
avcodec/exr: Check for pixel type consistency in DWA
Fixes: out of array access
Fixes: BIGSLEEP-436511754/testcase.exr
Found-by: Google Big Sleep
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
diff --git a/libavcodec/exr.c b/libavcodec/exr.c
index dea612a42b..67f971ff35 100644
--- a/libavcodec/exr.c
+++ b/libavcodec/exr.c
@@ -2086,6 +2086,17 @@ static int decode_frame(AVCodecContext *avctx, AVFrame *picture,
if ((ret = decode_header(s, picture)) < 0)
return ret;
+ if (s->compression == EXR_DWAA ||
+ s->compression == EXR_DWAB) {
+ for (int i = 0; i<s->nb_channels; i++) {
+ EXRChannel *channel = &s->channels[i];
+ if (channel->pixel_type != s->pixel_type) {
+ avpriv_request_sample(s->avctx, "mixed pixel type DWA");
+ return AVERROR_PATCHWELCOME;
+ }
+ }
+ }
+
switch (s->pixel_type) {
case EXR_HALF:
if (s->channel_offsets[3] >= 0) {
-----------------------------------------------------------------------
Summary of changes:
libavcodec/exr.c | 11 +++++++++++
1 file changed, 11 insertions(+)
hooks/post-receive
--
More information about the ffmpeg-cvslog
mailing list