fix CVE-2023-51793

This commit is contained in:
happyworker 2024-07-02 10:53:01 +08:00
parent 43199cbd35
commit 49f7e0c6ce
2 changed files with 41 additions and 1 deletions

View File

@ -61,7 +61,7 @@ ExclusiveArch: armv7hnl
Summary: Digital VCR and streaming server
Name: ffmpeg%{?flavor}
Version: 4.2.4
Release: 8
Release: 9
License: %{ffmpeg_license}
URL: http://ffmpeg.org/
%if 0%{?date}
@ -79,6 +79,7 @@ Patch6: CVE-2024-31578.patch
Patch7: CVE-2023-51794.patch
Patch8: fix-CVE-2023-51798.patch
Patch9: CVE-2022-3341.patch
Patch10: fix-CVE-2023-51793.patch
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
%{?_with_cuda:BuildRequires: cuda-minimal-build-%{_cuda_version_rpm} cuda-drivers-devel}
%{?_with_libnpp:BuildRequires: pkgconfig(nppc-%{_cuda_version})}
@ -411,6 +412,9 @@ install -pm755 tools/qt-faststart %{buildroot}%{_bindir}
%changelog
* Tue Jul 02 2024 happyworker <208suo@208suo.com> - 4.2.4-9
- Fix CVE-2023-51793
* Tue Jun 25 2024 happyworker <208suo@208suo.com> - 4.2.4-8
- Fix CVE-2022-3341

36
fix-CVE-2023-51793.patch Normal file
View File

@ -0,0 +1,36 @@
From 2658cd930f952b6bd32ee48a7430a6ba42a45643 Mon Sep 17 00:00:00 2001
From: Michael Niedermayer <michael@niedermayer.cc>
Date: Thu, 27 Jun 2024 13:46:29 +0800
Subject: [PATCH] fix CVE-2023-51793
---
libavfilter/vf_weave.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/libavfilter/vf_weave.c b/libavfilter/vf_weave.c
index 663d79f..fafaaa0 100644
--- a/libavfilter/vf_weave.c
+++ b/libavfilter/vf_weave.c
@@ -30,6 +30,7 @@ typedef struct WeaveContext {
int double_weave;
int nb_planes;
int planeheight[4];
+ int outheight[4];
int linesize[4];
AVFrame *prev;
@@ -71,7 +72,10 @@ static int config_props_output(AVFilterLink *outlink)
s->planeheight[1] = s->planeheight[2] = AV_CEIL_RSHIFT(inlink->h, desc->log2_chroma_h);
s->planeheight[0] = s->planeheight[3] = inlink->h;
-
+
+ s->outheight[1] = s->outheight[2] = AV_CEIL_RSHIFT(2*inlink->h, desc->log2_chroma_h);
+ s->outheight[0] = s->outheight[3] = 2*inlink->h;
+
s->nb_planes = av_pix_fmt_count_planes(inlink->format);
return 0;
--
2.43.0