forked from pool/ffmpeg-4
Compare commits
8 Commits
Author | SHA256 | Date | |
---|---|---|---|
8fbdfb91bd | |||
|
de5b65985a | ||
b13cda9bd1 | |||
|
d18dbae0d6 | ||
b301d907ff | |||
|
82796a5fd1 | ||
ef878de573 | |||
|
531ea6d843 |
@ -1,47 +0,0 @@
|
|||||||
From c3c8f97a9804b4234e97f13b0057ffc2c9af27c0 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Christopher Degawa <christopher.degawa@intel.com>
|
|
||||||
Date: Thu, 20 Oct 2022 22:55:27 -0500
|
|
||||||
Subject: [PATCH] avcodec/libsvtav1: remove compressed_ten_bit_format and
|
|
||||||
simplify alloc_buffer
|
|
||||||
|
|
||||||
compressed_ten_bit_format has been deprecated upstream and has no effect
|
|
||||||
and can be removed. Plus, technically it was never used in the first place
|
|
||||||
since it would require the app (ffmpeg) to set it and do additional
|
|
||||||
processing of the input frames.
|
|
||||||
|
|
||||||
Also simplify alloc_buffer by removing calculations relating to the
|
|
||||||
non-existant processing.
|
|
||||||
|
|
||||||
Signed-off-by: Christopher Degawa <christopher.degawa@intel.com>
|
|
||||||
(cherry picked from commit 031f1561cd286596cdb374da32f8aa816ce3b135)
|
|
||||||
---
|
|
||||||
libavcodec/libsvtav1.c | 10 +++-------
|
|
||||||
1 file changed, 3 insertions(+), 7 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/libavcodec/libsvtav1.c b/libavcodec/libsvtav1.c
|
|
||||||
index cfd93a2484..38777b0fb7 100644
|
|
||||||
--- a/libavcodec/libsvtav1.c
|
|
||||||
+++ b/libavcodec/libsvtav1.c
|
|
||||||
@@ -120,16 +120,12 @@ static int svt_print_error(void *log_ctx, EbErrorType err,
|
|
||||||
|
|
||||||
static int alloc_buffer(EbSvtAv1EncConfiguration *config, SvtContext *svt_enc)
|
|
||||||
{
|
|
||||||
- const int pack_mode_10bit =
|
|
||||||
- (config->encoder_bit_depth > 8) && (config->compressed_ten_bit_format == 0) ? 1 : 0;
|
|
||||||
- const size_t luma_size_8bit =
|
|
||||||
- config->source_width * config->source_height * (1 << pack_mode_10bit);
|
|
||||||
- const size_t luma_size_10bit =
|
|
||||||
- (config->encoder_bit_depth > 8 && pack_mode_10bit == 0) ? luma_size_8bit : 0;
|
|
||||||
+ const size_t luma_size = config->source_width * config->source_height *
|
|
||||||
+ (config->encoder_bit_depth > 8 ? 2 : 1);
|
|
||||||
|
|
||||||
EbSvtIOFormat *in_data;
|
|
||||||
|
|
||||||
- svt_enc->raw_size = (luma_size_8bit + luma_size_10bit) * 3 / 2;
|
|
||||||
+ svt_enc->raw_size = luma_size * 3 / 2;
|
|
||||||
|
|
||||||
// allocate buffer for in and out
|
|
||||||
svt_enc->in_buf = av_mallocz(sizeof(*svt_enc->in_buf));
|
|
||||||
--
|
|
||||||
2.41.0
|
|
||||||
|
|
@ -1,76 +0,0 @@
|
|||||||
From effadce6c756247ea8bae32dc13bb3e6f464f0eb Mon Sep 17 00:00:00 2001
|
|
||||||
From: =?UTF-8?q?R=C3=A9mi=20Denis-Courmont?= <remi@remlab.net>
|
|
||||||
Date: Sun, 16 Jul 2023 18:18:02 +0300
|
|
||||||
Subject: [PATCH] avcodec/x86/mathops: clip constants used with shift
|
|
||||||
instructions within inline assembly
|
|
||||||
|
|
||||||
Fixes assembling with binutil as >= 2.41
|
|
||||||
|
|
||||||
Signed-off-by: James Almer <jamrial@gmail.com>
|
|
||||||
---
|
|
||||||
libavcodec/x86/mathops.h | 26 +++++++++++++++++++++++---
|
|
||||||
1 file changed, 23 insertions(+), 3 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/libavcodec/x86/mathops.h b/libavcodec/x86/mathops.h
|
|
||||||
index 6298f5ed19..ca7e2dffc1 100644
|
|
||||||
--- a/libavcodec/x86/mathops.h
|
|
||||||
+++ b/libavcodec/x86/mathops.h
|
|
||||||
@@ -35,12 +35,20 @@
|
|
||||||
static av_always_inline av_const int MULL(int a, int b, unsigned shift)
|
|
||||||
{
|
|
||||||
int rt, dummy;
|
|
||||||
+ if (__builtin_constant_p(shift))
|
|
||||||
__asm__ (
|
|
||||||
"imull %3 \n\t"
|
|
||||||
"shrdl %4, %%edx, %%eax \n\t"
|
|
||||||
:"=a"(rt), "=d"(dummy)
|
|
||||||
- :"a"(a), "rm"(b), "ci"((uint8_t)shift)
|
|
||||||
+ :"a"(a), "rm"(b), "i"(shift & 0x1F)
|
|
||||||
);
|
|
||||||
+ else
|
|
||||||
+ __asm__ (
|
|
||||||
+ "imull %3 \n\t"
|
|
||||||
+ "shrdl %4, %%edx, %%eax \n\t"
|
|
||||||
+ :"=a"(rt), "=d"(dummy)
|
|
||||||
+ :"a"(a), "rm"(b), "c"((uint8_t)shift)
|
|
||||||
+ );
|
|
||||||
return rt;
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -113,19 +121,31 @@ __asm__ volatile(\
|
|
||||||
// avoid +32 for shift optimization (gcc should do that ...)
|
|
||||||
#define NEG_SSR32 NEG_SSR32
|
|
||||||
static inline int32_t NEG_SSR32( int32_t a, int8_t s){
|
|
||||||
+ if (__builtin_constant_p(s))
|
|
||||||
__asm__ ("sarl %1, %0\n\t"
|
|
||||||
: "+r" (a)
|
|
||||||
- : "ic" ((uint8_t)(-s))
|
|
||||||
+ : "i" (-s & 0x1F)
|
|
||||||
);
|
|
||||||
+ else
|
|
||||||
+ __asm__ ("sarl %1, %0\n\t"
|
|
||||||
+ : "+r" (a)
|
|
||||||
+ : "c" ((uint8_t)(-s))
|
|
||||||
+ );
|
|
||||||
return a;
|
|
||||||
}
|
|
||||||
|
|
||||||
#define NEG_USR32 NEG_USR32
|
|
||||||
static inline uint32_t NEG_USR32(uint32_t a, int8_t s){
|
|
||||||
+ if (__builtin_constant_p(s))
|
|
||||||
__asm__ ("shrl %1, %0\n\t"
|
|
||||||
: "+r" (a)
|
|
||||||
- : "ic" ((uint8_t)(-s))
|
|
||||||
+ : "i" (-s & 0x1F)
|
|
||||||
);
|
|
||||||
+ else
|
|
||||||
+ __asm__ ("shrl %1, %0\n\t"
|
|
||||||
+ : "+r" (a)
|
|
||||||
+ : "c" ((uint8_t)(-s))
|
|
||||||
+ );
|
|
||||||
return a;
|
|
||||||
}
|
|
||||||
|
|
||||||
--
|
|
||||||
2.42.0
|
|
||||||
|
|
@ -1,29 +0,0 @@
|
|||||||
From 50f0f8c53c818f73fe2d752708e2fa9d2a2d8a07 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Michael Niedermayer <michael@niedermayer.cc>
|
|
||||||
Date: Sat, 23 Dec 2023 04:03:01 +0100
|
|
||||||
Subject: [PATCH] avfilter/af_stereowiden: Check length
|
|
||||||
References: https://bugzilla.opensuse.org/1223437
|
|
||||||
References: CVE-2023-51794
|
|
||||||
|
|
||||||
Fixes: out of array access
|
|
||||||
Fixes: tickets/10746/poc13ffmpeg
|
|
||||||
|
|
||||||
Found-by: Zeng Yunxiang
|
|
||||||
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
|
|
||||||
---
|
|
||||||
libavfilter/af_stereowiden.c | 2 ++
|
|
||||||
1 file changed, 2 insertions(+)
|
|
||||||
|
|
||||||
Index: ffmpeg-4.4.4/libavfilter/af_stereowiden.c
|
|
||||||
===================================================================
|
|
||||||
--- ffmpeg-4.4.4.orig/libavfilter/af_stereowiden.c
|
|
||||||
+++ ffmpeg-4.4.4/libavfilter/af_stereowiden.c
|
|
||||||
@@ -75,6 +75,8 @@ static int config_input(AVFilterLink *in
|
|
||||||
|
|
||||||
s->length = s->delay * inlink->sample_rate / 1000;
|
|
||||||
s->length *= 2;
|
|
||||||
+ if (s->length == 0)
|
|
||||||
+ return AVERROR(EINVAL);
|
|
||||||
s->buffer = av_calloc(s->length, sizeof(*s->buffer));
|
|
||||||
if (!s->buffer)
|
|
||||||
return AVERROR(ENOMEM);
|
|
@ -1,40 +0,0 @@
|
|||||||
From 68146f06f852078866b3ef1564556e3a272920c7 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Michael Niedermayer <michael@niedermayer.cc>
|
|
||||||
Date: Sat, 30 Dec 2023 02:51:32 +0100
|
|
||||||
Subject: [PATCH] avfilter/vf_minterpolate: Check pts before division
|
|
||||||
References: https://bugzilla.opensuse.org/1223304
|
|
||||||
References: CVE-2023-51798
|
|
||||||
|
|
||||||
Fixes: FPE
|
|
||||||
Fixes: tickets/10758/poc20ffmpeg
|
|
||||||
|
|
||||||
Discovered by Zeng Yunxiang
|
|
||||||
|
|
||||||
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
|
|
||||||
---
|
|
||||||
libavfilter/vf_minterpolate.c | 9 +++++++--
|
|
||||||
1 file changed, 7 insertions(+), 2 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/libavfilter/vf_minterpolate.c b/libavfilter/vf_minterpolate.c
|
|
||||||
index 9920210ece..b2242a15ee 100644
|
|
||||||
--- a/libavfilter/vf_minterpolate.c
|
|
||||||
+++ b/libavfilter/vf_minterpolate.c
|
|
||||||
@@ -1075,8 +1075,13 @@ static void interpolate(AVFilterLink *inlink, AVFrame *avf_out)
|
|
||||||
pts = av_rescale(avf_out->pts, (int64_t) ALPHA_MAX * outlink->time_base.num * inlink->time_base.den,
|
|
||||||
(int64_t) outlink->time_base.den * inlink->time_base.num);
|
|
||||||
|
|
||||||
- alpha = (pts - mi_ctx->frames[1].avf->pts * ALPHA_MAX) / (mi_ctx->frames[2].avf->pts - mi_ctx->frames[1].avf->pts);
|
|
||||||
- alpha = av_clip(alpha, 0, ALPHA_MAX);
|
|
||||||
+ if (mi_ctx->frames[2].avf->pts > mi_ctx->frames[1].avf->pts) {
|
|
||||||
+ alpha = (pts - mi_ctx->frames[1].avf->pts * ALPHA_MAX) / (mi_ctx->frames[2].avf->pts - mi_ctx->frames[1].avf->pts);
|
|
||||||
+ alpha = av_clip(alpha, 0, ALPHA_MAX);
|
|
||||||
+ } else {
|
|
||||||
+ av_log(ctx, AV_LOG_DEBUG, "duplicate input PTS detected\n");
|
|
||||||
+ alpha = 0;
|
|
||||||
+ }
|
|
||||||
|
|
||||||
if (alpha == 0 || alpha == ALPHA_MAX) {
|
|
||||||
av_frame_copy(avf_out, alpha ? mi_ctx->frames[2].avf : mi_ctx->frames[1].avf);
|
|
||||||
--
|
|
||||||
2.44.0
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
mtime: 1724842934
|
mtime: 1740428378
|
||||||
commit: 9e43e5445b98d8995b81b0fc26eca3b5334fb0e654fa27f34d5f3cd90ff11654
|
commit: 71230d5ab33ebb8b540bce6771743d3d17a008cbe9ffb2831c8c2522bb9e4f9a
|
||||||
url: https://src.opensuse.org/jengelh/ffmpeg-4
|
url: https://src.opensuse.org/jengelh/ffmpeg-4
|
||||||
revision: master
|
revision: master
|
||||||
|
BIN
build.specials.obscpio
(Stored with Git LFS)
BIN
build.specials.obscpio
(Stored with Git LFS)
Binary file not shown.
32
ffmpeg-4-CVE-2024-12361.patch
Normal file
32
ffmpeg-4-CVE-2024-12361.patch
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
From 4065ff69a2ed49872f8694a03d0642b18c9d977c Mon Sep 17 00:00:00 2001
|
||||||
|
From: Jiasheng Jiang <jiashengjiangcool@outlook.com>
|
||||||
|
Date: Mon, 10 Jun 2024 14:18:11 +0000
|
||||||
|
Subject: [PATCH] avcodec/mpegvideo_enc: Add check for
|
||||||
|
av_packet_new_side_data()
|
||||||
|
|
||||||
|
Add check for av_packet_new_side_data() to avoid null pointer
|
||||||
|
dereference if allocation fails.
|
||||||
|
|
||||||
|
Fixes: bdc1220eeb ("h263enc: Add an option for outputting info about MBs as side data")
|
||||||
|
Signed-off-by: Jiasheng Jiang <jiashengjiangcool@outlook.com>
|
||||||
|
Signed-off-by: Anton Khirnov <anton@khirnov.net>
|
||||||
|
---
|
||||||
|
libavcodec/mpegvideo_enc.c | 2 ++
|
||||||
|
1 file changed, 2 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
|
||||||
|
index 620ca08869..d33754d115 100644
|
||||||
|
--- a/libavcodec/mpegvideo_enc.c
|
||||||
|
+++ b/libavcodec/mpegvideo_enc.c
|
||||||
|
@@ -1825,6 +1825,8 @@ int ff_mpv_encode_picture(AVCodecContext *avctx, AVPacket *pkt,
|
||||||
|
s->mb_info_ptr = av_packet_new_side_data(pkt,
|
||||||
|
AV_PKT_DATA_H263_MB_INFO,
|
||||||
|
s->mb_width*s->mb_height*12);
|
||||||
|
+ if (!s->mb_info_ptr)
|
||||||
|
+ return AVERROR(ENOMEM);
|
||||||
|
s->prev_mb_info = s->last_mb_info = s->mb_info_size = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
--
|
||||||
|
2.44.0
|
||||||
|
|
@ -1,23 +0,0 @@
|
|||||||
commit 96449cfeaeb95fcfd7a2b8d9ccf7719e97471ed1
|
|
||||||
Author: Michael Niedermayer <michael@niedermayer.cc>
|
|
||||||
Date: Mon Apr 8 18:38:42 2024 +0200
|
|
||||||
|
|
||||||
avcodec/mpegvideo_enc: Fix 1 line and one column images
|
|
||||||
|
|
||||||
Fixes: Ticket10952
|
|
||||||
Fixes: poc21ffmpeg
|
|
||||||
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
|
|
||||||
|
|
||||||
--- ffmpeg-4.4.4/libavcodec/mpegvideo_enc.c
|
|
||||||
+++ ffmpeg-4.4.4_new/libavcodec/mpegvideo_enc.c
|
|
||||||
@@ -1263,8 +1263,8 @@
|
|
||||||
int dst_stride = i ? s->uvlinesize : s->linesize;
|
|
||||||
int h_shift = i ? h_chroma_shift : 0;
|
|
||||||
int v_shift = i ? v_chroma_shift : 0;
|
|
||||||
- int w = s->width >> h_shift;
|
|
||||||
- int h = s->height >> v_shift;
|
|
||||||
+ int w = AV_CEIL_RSHIFT(s->width , h_shift);
|
|
||||||
+ int h = AV_CEIL_RSHIFT(s->height, v_shift);
|
|
||||||
uint8_t *src = pic_arg->data[i];
|
|
||||||
uint8_t *dst = pic->f->data[i];
|
|
||||||
int vpad = 16;
|
|
29
ffmpeg-4-CVE-2025-0518.patch
Normal file
29
ffmpeg-4-CVE-2025-0518.patch
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
From b5b6391d64807578ab872dc58fb8aa621dcfc38a Mon Sep 17 00:00:00 2001
|
||||||
|
From: Michael Niedermayer <michael@niedermayer.cc>
|
||||||
|
Date: Mon, 6 Jan 2025 22:01:39 +0100
|
||||||
|
Subject: [PATCH] avfilter/af_pan: Fix sscanf() use
|
||||||
|
|
||||||
|
Fixes: Memory Data Leak
|
||||||
|
|
||||||
|
Found-by: Simcha Kosman <simcha.kosman@cyberark.com>
|
||||||
|
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
|
||||||
|
---
|
||||||
|
libavfilter/af_pan.c | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/libavfilter/af_pan.c b/libavfilter/af_pan.c
|
||||||
|
index 0d20b0307b..5feb2439c7 100644
|
||||||
|
--- a/libavfilter/af_pan.c
|
||||||
|
+++ b/libavfilter/af_pan.c
|
||||||
|
@@ -196,7 +196,7 @@ static av_cold int init(AVFilterContext *ctx)
|
||||||
|
sign = 1;
|
||||||
|
while (1) {
|
||||||
|
gain = 1;
|
||||||
|
- if (sscanf(arg, "%lf%n *%n", &gain, &len, &len))
|
||||||
|
+ if (sscanf(arg, "%lf%n *%n", &gain, &len, &len) >= 1)
|
||||||
|
arg += len;
|
||||||
|
if (parse_channel_name(&arg, &in_ch_id, &named)){
|
||||||
|
av_log(ctx, AV_LOG_ERROR,
|
||||||
|
--
|
||||||
|
2.44.0
|
||||||
|
|
29
ffmpeg-4-CVE-2025-22919.patch
Normal file
29
ffmpeg-4-CVE-2025-22919.patch
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
From 1446e37d3d032e1452844778b3e6ba2c20f0c322 Mon Sep 17 00:00:00 2001
|
||||||
|
From: James Almer <jamrial@gmail.com>
|
||||||
|
Date: Mon, 30 Dec 2024 00:25:41 -0300
|
||||||
|
Subject: [PATCH] avfilter/buffersrc: check for valid sample rate
|
||||||
|
|
||||||
|
A sample rate <= 0 is invalid.
|
||||||
|
|
||||||
|
Fixes an assert in ffmpeg_enc.c that assumed a valid sample rate would be set.
|
||||||
|
Fixes ticket #11385.
|
||||||
|
|
||||||
|
Signed-off-by: James Almer <jamrial@gmail.com>
|
||||||
|
---
|
||||||
|
libavfilter/buffersrc.c | 5 +++++
|
||||||
|
1 file changed, 5 insertions(+)
|
||||||
|
|
||||||
|
--- a/libavfilter/buffersrc.c
|
||||||
|
+++ b/libavfilter/buffersrc.c
|
||||||
|
@@ -337,6 +337,11 @@
|
||||||
|
return AVERROR(EINVAL);
|
||||||
|
}
|
||||||
|
|
||||||
|
+ if (s->sample_rate <= 0) {
|
||||||
|
+ av_log(ctx, AV_LOG_ERROR, "Sample rate not set\n");
|
||||||
|
+ return AVERROR(EINVAL);
|
||||||
|
+ }
|
||||||
|
+
|
||||||
|
if (!s->time_base.num)
|
||||||
|
s->time_base = (AVRational){1, s->sample_rate};
|
||||||
|
|
29
ffmpeg-4-CVE-2025-22921.patch
Normal file
29
ffmpeg-4-CVE-2025-22921.patch
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
From 7f9c7f9849a2155224711f0ff57ecdac6e4bfb57 Mon Sep 17 00:00:00 2001
|
||||||
|
From: James Almer <jamrial@gmail.com>
|
||||||
|
Date: Wed, 1 Jan 2025 23:58:39 -0300
|
||||||
|
Subject: [PATCH] avcodec/jpeg2000dec: clear array length when freeing it
|
||||||
|
|
||||||
|
Fixes NULL pointer dereferences.
|
||||||
|
Fixes ticket #11393.
|
||||||
|
|
||||||
|
Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
|
||||||
|
Signed-off-by: James Almer <jamrial@gmail.com>
|
||||||
|
---
|
||||||
|
libavcodec/jpeg2000dec.c | 1 +
|
||||||
|
1 file changed, 1 insertion(+)
|
||||||
|
|
||||||
|
diff --git a/libavcodec/jpeg2000dec.c b/libavcodec/jpeg2000dec.c
|
||||||
|
index e5e897a29f..b82d85d5ee 100644
|
||||||
|
--- a/libavcodec/jpeg2000dec.c
|
||||||
|
+++ b/libavcodec/jpeg2000dec.c
|
||||||
|
@@ -1521,6 +1521,7 @@ static int jpeg2000_decode_packet(Jpeg2000DecoderContext *s, Jpeg2000Tile *tile,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
av_freep(&cblk->lengthinc);
|
||||||
|
+ cblk->nb_lengthinc = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// Save state of stream
|
||||||
|
--
|
||||||
|
2.44.0
|
||||||
|
|
26
ffmpeg-4-CVE-2025-25473.patch
Normal file
26
ffmpeg-4-CVE-2025-25473.patch
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
From c08d300481b8ebb846cd43a473988fdbc6793d1b Mon Sep 17 00:00:00 2001
|
||||||
|
From: James Almer <jamrial@gmail.com>
|
||||||
|
Date: Fri, 17 Jan 2025 00:05:31 -0300
|
||||||
|
Subject: [PATCH] avformat/avformat: also clear FFFormatContext packet queue
|
||||||
|
when closing a muxer
|
||||||
|
|
||||||
|
packet_buffer is used in mux.c, and if a muxing process fails at a point where
|
||||||
|
packets remained in said queue, they will leak.
|
||||||
|
|
||||||
|
Fixes ticket #11419
|
||||||
|
|
||||||
|
Signed-off-by: James Almer <jamrial@gmail.com>
|
||||||
|
---
|
||||||
|
libavformat/avformat.c | 1 +
|
||||||
|
1 file changed, 1 insertion(+)
|
||||||
|
|
||||||
|
--- a/libavformat/utils.c
|
||||||
|
+++ b/libavformat/utils.c
|
||||||
|
@@ -4478,6 +4478,7 @@
|
||||||
|
av_dict_free(&s->internal->id3v2_meta);
|
||||||
|
av_packet_free(&s->internal->pkt);
|
||||||
|
av_packet_free(&s->internal->parse_pkt);
|
||||||
|
+ avpriv_packet_list_free(&s->internal->packet_buffer, &s->internal->packet_buffer_end);
|
||||||
|
av_freep(&s->streams);
|
||||||
|
flush_packet_queue(s);
|
||||||
|
av_freep(&s->internal);
|
@ -1,7 +1,14 @@
|
|||||||
Index: ffmpeg-4.4.3/configure
|
---
|
||||||
|
configure | 3 ++
|
||||||
|
libavcodec/dlopen.h | 12 ++++++++++
|
||||||
|
libavcodec/libfdk-aacdec.c | 53 +++++++++++++++++++++++++++++++++++++++++++++
|
||||||
|
libavcodec/libfdk-aacenc.c | 47 +++++++++++++++++++++++++++++++++++++++
|
||||||
|
4 files changed, 115 insertions(+)
|
||||||
|
|
||||||
|
Index: ffmpeg-4.4.5/configure
|
||||||
===================================================================
|
===================================================================
|
||||||
--- ffmpeg-4.4.3.orig/configure
|
--- ffmpeg-4.4.5.orig/configure
|
||||||
+++ ffmpeg-4.4.3/configure
|
+++ ffmpeg-4.4.5/configure
|
||||||
@@ -232,6 +232,7 @@ External library support:
|
@@ -232,6 +232,7 @@ External library support:
|
||||||
--enable-libdc1394 enable IIDC-1394 grabbing using libdc1394
|
--enable-libdc1394 enable IIDC-1394 grabbing using libdc1394
|
||||||
and libraw1394 [no]
|
and libraw1394 [no]
|
||||||
@ -15,10 +22,10 @@ Index: ffmpeg-4.4.3/configure
|
|||||||
decklink
|
decklink
|
||||||
libfdk_aac
|
libfdk_aac
|
||||||
+ libfdk_aac_dlopen
|
+ libfdk_aac_dlopen
|
||||||
openssl
|
|
||||||
libtls
|
libtls
|
||||||
"
|
"
|
||||||
@@ -6368,6 +6370,7 @@ enabled libdrm && require_pkg
|
|
||||||
|
@@ -6370,6 +6372,7 @@ enabled libdrm && require_pkg
|
||||||
enabled libfdk_aac && { check_pkg_config libfdk_aac fdk-aac "fdk-aac/aacenc_lib.h" aacEncOpen ||
|
enabled libfdk_aac && { check_pkg_config libfdk_aac fdk-aac "fdk-aac/aacenc_lib.h" aacEncOpen ||
|
||||||
{ require libfdk_aac fdk-aac/aacenc_lib.h aacEncOpen -lfdk-aac &&
|
{ require libfdk_aac fdk-aac/aacenc_lib.h aacEncOpen -lfdk-aac &&
|
||||||
warn "using libfdk without pkg-config"; } }
|
warn "using libfdk without pkg-config"; } }
|
||||||
@ -26,10 +33,10 @@ Index: ffmpeg-4.4.3/configure
|
|||||||
flite_extralibs="-lflite_cmu_time_awb -lflite_cmu_us_awb -lflite_cmu_us_kal -lflite_cmu_us_kal16 -lflite_cmu_us_rms -lflite_cmu_us_slt -lflite_usenglish -lflite_cmulex -lflite"
|
flite_extralibs="-lflite_cmu_time_awb -lflite_cmu_us_awb -lflite_cmu_us_kal -lflite_cmu_us_kal16 -lflite_cmu_us_rms -lflite_cmu_us_slt -lflite_usenglish -lflite_cmulex -lflite"
|
||||||
enabled libflite && require libflite "flite/flite.h" flite_init $flite_extralibs
|
enabled libflite && require libflite "flite/flite.h" flite_init $flite_extralibs
|
||||||
enabled fontconfig && enable libfontconfig
|
enabled fontconfig && enable libfontconfig
|
||||||
Index: ffmpeg-4.4.3/libavcodec/dlopen.h
|
Index: ffmpeg-4.4.5/libavcodec/dlopen.h
|
||||||
===================================================================
|
===================================================================
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ ffmpeg-4.4.3/libavcodec/dlopen.h
|
+++ ffmpeg-4.4.5/libavcodec/dlopen.h
|
||||||
@@ -0,0 +1,12 @@
|
@@ -0,0 +1,12 @@
|
||||||
+#ifndef LOCALINC_DLOPEN_H
|
+#ifndef LOCALINC_DLOPEN_H
|
||||||
+#define LOCALINC_DLOPEN_H
|
+#define LOCALINC_DLOPEN_H
|
||||||
@ -43,10 +50,10 @@ Index: ffmpeg-4.4.3/libavcodec/dlopen.h
|
|||||||
+ goto error;
|
+ goto error;
|
||||||
+
|
+
|
||||||
+#endif
|
+#endif
|
||||||
Index: ffmpeg-4.4.3/libavcodec/libfdk-aacdec.c
|
Index: ffmpeg-4.4.5/libavcodec/libfdk-aacdec.c
|
||||||
===================================================================
|
===================================================================
|
||||||
--- ffmpeg-4.4.3.orig/libavcodec/libfdk-aacdec.c
|
--- ffmpeg-4.4.5.orig/libavcodec/libfdk-aacdec.c
|
||||||
+++ ffmpeg-4.4.3/libavcodec/libfdk-aacdec.c
|
+++ ffmpeg-4.4.5/libavcodec/libfdk-aacdec.c
|
||||||
@@ -37,6 +37,54 @@
|
@@ -37,6 +37,54 @@
|
||||||
#define AAC_PCM_MAX_OUTPUT_CHANNELS AAC_PCM_OUTPUT_CHANNELS
|
#define AAC_PCM_MAX_OUTPUT_CHANNELS AAC_PCM_OUTPUT_CHANNELS
|
||||||
#endif
|
#endif
|
||||||
@ -114,10 +121,10 @@ Index: ffmpeg-4.4.3/libavcodec/libfdk-aacdec.c
|
|||||||
s->handle = aacDecoder_Open(avctx->extradata_size ? TT_MP4_RAW : TT_MP4_ADTS, 1);
|
s->handle = aacDecoder_Open(avctx->extradata_size ? TT_MP4_RAW : TT_MP4_ADTS, 1);
|
||||||
if (!s->handle) {
|
if (!s->handle) {
|
||||||
av_log(avctx, AV_LOG_ERROR, "Error opening decoder\n");
|
av_log(avctx, AV_LOG_ERROR, "Error opening decoder\n");
|
||||||
Index: ffmpeg-4.4.3/libavcodec/libfdk-aacenc.c
|
Index: ffmpeg-4.4.5/libavcodec/libfdk-aacenc.c
|
||||||
===================================================================
|
===================================================================
|
||||||
--- ffmpeg-4.4.3.orig/libavcodec/libfdk-aacenc.c
|
--- ffmpeg-4.4.5.orig/libavcodec/libfdk-aacenc.c
|
||||||
+++ ffmpeg-4.4.3/libavcodec/libfdk-aacenc.c
|
+++ ffmpeg-4.4.5/libavcodec/libfdk-aacenc.c
|
||||||
@@ -35,6 +35,48 @@
|
@@ -35,6 +35,48 @@
|
||||||
#define FDKENC_VER_AT_LEAST(vl0, vl1) 0
|
#define FDKENC_VER_AT_LEAST(vl0, vl1) 0
|
||||||
#endif
|
#endif
|
||||||
|
BIN
ffmpeg-4.4.4.tar.xz
(Stored with Git LFS)
BIN
ffmpeg-4.4.4.tar.xz
(Stored with Git LFS)
Binary file not shown.
@ -1,11 +0,0 @@
|
|||||||
-----BEGIN PGP SIGNATURE-----
|
|
||||||
|
|
||||||
iQFMBAABCAA2FiEE/PmG6hXm4pOlZE8QtDIvBNZ2WNgFAmQ2/oUYHGZmbXBlZy1k
|
|
||||||
ZXZlbEBmZm1wZWcub3JnAAoJELQyLwTWdljYkGMH/iRlBGO1ZcCPnNpJt6pAqxcY
|
|
||||||
cP4hmanIPLLBPQfbHIwGUJDiTDIpXuFeWC7dt08Q8ndXtXbjTJ0T+hZP7Riuzns8
|
|
||||||
bwXfrCRioKlmIZSUg9WMErNW+vE/nUFn20q4PdzaWbeUbIsZEW6Btt4C4JuBCLsn
|
|
||||||
K2WZa7/GwaMnLLPIUIaNzW//aeUj11IhY74qB3k5nOhidgptY1en7xa9x1kZ3dvW
|
|
||||||
wx2vO+2fS5SlvBfj2KFAey+FX2LAEZFjRaiWRnzlO5daqO4acWMtRAQeMk5rs21W
|
|
||||||
NeTZUqZoPaaNfcFz1yWsBv19Fte4R9D8oD4TwMd5ikZZ2hjV+N+EMEFNWLoH02Q=
|
|
||||||
=e6RR
|
|
||||||
-----END PGP SIGNATURE-----
|
|
BIN
ffmpeg-4.4.5.tar.xz
(Stored with Git LFS)
Normal file
BIN
ffmpeg-4.4.5.tar.xz
(Stored with Git LFS)
Normal file
Binary file not shown.
11
ffmpeg-4.4.5.tar.xz.asc
Normal file
11
ffmpeg-4.4.5.tar.xz.asc
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
-----BEGIN PGP SIGNATURE-----
|
||||||
|
|
||||||
|
iQFMBAABCgA2FiEE/PmG6hXm4pOlZE8QtDIvBNZ2WNgFAmamzJUYHGZmbXBlZy1k
|
||||||
|
ZXZlbEBmZm1wZWcub3JnAAoJELQyLwTWdljYZP8H/27rVRh4/NOvhP5JN2FhhWfo
|
||||||
|
BmAYgHWLag3a8P4yShGGgxhLjnd7LKOdSTIOb67Q7CgqzsQCV7c+VgUp068uhCod
|
||||||
|
J0TgnefWzw+iR3zupKEVRoFEsy/3A5RWXVWx42B7WTpkkShQWXaPHvUdH9ELwwfK
|
||||||
|
mq3TQMygmjjzDIa677i3uNUrb2CGyxdUXqGzmatUfrtXm0/mqUtz41neS5tuLQn5
|
||||||
|
xXcpmtsElkLK4ZaQWRC8w6emEyx49MqyRw7tTjIh/lPN+KTBUtcrYgDeCJt25H9s
|
||||||
|
2Hm9Obax0z2fPi71eP7GkbVXrGmwL1DcSegFW+TCW5CniWkWaWKe4+qDMepPtIo=
|
||||||
|
=byXw
|
||||||
|
-----END PGP SIGNATURE-----
|
@ -1,3 +1,75 @@
|
|||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Feb 19 05:17:22 UTC 2025 - Cliff Zhao <qzhao@suse.com>
|
||||||
|
|
||||||
|
- Add ffmpeg-7-CVE-2025-22921.patch:
|
||||||
|
Backporting 7f9c7f98 from upstream, clear array length when
|
||||||
|
freeing it.
|
||||||
|
(CVE-2025-22921, bsc#1237382)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Feb 19 04:27:06 UTC 2025 - Cliff Zhao <qzhao@suse.com>
|
||||||
|
|
||||||
|
- Add ffmpeg-7-CVE-2025-25473.patch:
|
||||||
|
Backporting c08d3004 from upstream, clear FFFormatContext packet.
|
||||||
|
When packet_buffer is used in mux.c, and if a muxing process fails
|
||||||
|
at a point where packets remained in said queue.
|
||||||
|
(CVE-2025-25473, bsc#1237351)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Feb 19 03:18:02 UTC 2025 - Cliff Zhao <qzhao@suse.com>
|
||||||
|
|
||||||
|
- Add ffmpeg-7-CVE-2025-0518.patch:
|
||||||
|
Backporting b5b6391d from upstream, fixes memory data leak when
|
||||||
|
use sscanf().
|
||||||
|
(CVE-2025-0518, bsc#1236007)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Feb 19 02:58:01 UTC 2025 - Cliff Zhao <qzhao@suse.com>
|
||||||
|
|
||||||
|
- Add ffmpeg-7-CVE-2025-22919.patch:
|
||||||
|
Backporting 1446e37d from upstream, check for valid sample rate
|
||||||
|
As the sample rate <= 0 is invalid.
|
||||||
|
(CVE-2025-22919, bsc#1237371)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Feb 19 01:48:22 UTC 2025 - Cliff Zhao <qzhao@suse.com>
|
||||||
|
|
||||||
|
- Add ffmpeg-4-CVE-2024-12361.patch:
|
||||||
|
Backporting 4065ff69 from upstream, add check for av_packet_new_side_data()
|
||||||
|
to avoid null pointer dereference if allocation fails.
|
||||||
|
(CVE-2024-12361, bsc#1237358)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Tue Oct 15 08:18:54 UTC 2024 - Antonio Larrosa <alarrosa@suse.com>
|
||||||
|
|
||||||
|
- Adjust bconds to build the package in SLFO without xvidcore.
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Mon Jan 6 11:53:32 UTC 2025 - Jan Engelhardt <jengelh@inai.de>
|
||||||
|
|
||||||
|
- Update to release 4.4.5
|
||||||
|
* Reliability/bug fixes
|
||||||
|
Fixes: 51896/clusterfuzz-testcase-minimized-ffmpeg_dem_DXA_fuzzer-5730576523198464
|
||||||
|
Fixes: signed integer overflow: 2147483566 + 82 cannot be represented in type 'int'
|
||||||
|
(CVE-2024-36613, bsc#1235092)
|
||||||
|
- Delete
|
||||||
|
0001-avcodec-libsvtav1-remove-compressed_ten_bit_format-a.patch
|
||||||
|
0001-avcodec-x86-mathops-clip-constants-used-with-shift-i.patch
|
||||||
|
0001-avfilter-vf_minterpolate-Check-pts-before-division.patch
|
||||||
|
ffmpeg-CVE-2023-51793.patch
|
||||||
|
0001-avfilter-af_stereowiden-Check-length.patch
|
||||||
|
ffmpeg-CVE-2023-50010.patch
|
||||||
|
ffmpeg-4-CVE-2024-32230.patch
|
||||||
|
ffmpeg-4-CVE-2024-7055.patch (all merged)
|
||||||
|
|
||||||
|
-------------------------------------------------------------------
|
||||||
|
Fri Sep 6 15:06:21 UTC 2024 - Cliff Zhao <qzhao@suse.com>
|
||||||
|
|
||||||
|
- Add ffmpeg-4-CVE-2024-7055.patch:
|
||||||
|
Backporting 3faadbe2 from upstream, Use 64bit for input size check,
|
||||||
|
Fixes: out of array read, Fixes: poc3.
|
||||||
|
(CVE-2024-7055, bsc#1229026)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Wed Aug 28 10:42:38 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
|
Wed Aug 28 10:42:38 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
|
||||||
|
|
||||||
@ -22,7 +94,7 @@ Tue Apr 27 11:38:35 UTC 2024 - Cliff Zhao <qzhao@suse.com>
|
|||||||
|
|
||||||
- Add ffmpeg-CVE-2023-50010.patch:
|
- Add ffmpeg-CVE-2023-50010.patch:
|
||||||
Backporting e4d2666b from upstream, fixes the out of array access.
|
Backporting e4d2666b from upstream, fixes the out of array access.
|
||||||
(CVE-2023-50010 bsc#1223256)
|
(CVE-2023-a50010, bsc#1223256)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Fri Apr 26 22:16:48 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
|
Fri Apr 26 22:16:48 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
|
||||||
@ -35,7 +107,7 @@ Thu Apr 23 16:14:18 UTC 2024 - Cliff Zhao <qzhao@suse.com>
|
|||||||
|
|
||||||
- Add ffmpeg-CVE-2023-51793.patch:
|
- Add ffmpeg-CVE-2023-51793.patch:
|
||||||
Backporting 0ecc1f0e from upstream, Fix odd height handling.
|
Backporting 0ecc1f0e from upstream, Fix odd height handling.
|
||||||
(CVE-2023-51793 bsc#1223272)
|
(CVE-2023-51793, bsc#1223272)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Thu Apr 23 15:35:32 UTC 2024 - Cliff Zhao <qzhao@suse.com>
|
Thu Apr 23 15:35:32 UTC 2024 - Cliff Zhao <qzhao@suse.com>
|
||||||
@ -43,7 +115,7 @@ Thu Apr 23 15:35:32 UTC 2024 - Cliff Zhao <qzhao@suse.com>
|
|||||||
- Add ffmpeg-CVE-2023-49502.patch:
|
- Add ffmpeg-CVE-2023-49502.patch:
|
||||||
Backporting 737ede40 from upstream, account for chroma sub-sampling
|
Backporting 737ede40 from upstream, account for chroma sub-sampling
|
||||||
in min size calculation.
|
in min size calculation.
|
||||||
(CVE-2023-49502 bsc#1223235)
|
(CVE-2023-49502, bsc#1223235)
|
||||||
|
|
||||||
-------------------------------------------------------------------
|
-------------------------------------------------------------------
|
||||||
Tue Apr 23 14:25:53 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
|
Tue Apr 23 14:25:53 UTC 2024 - Jan Engelhardt <jengelh@inai.de>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#
|
#
|
||||||
# spec file for package ffmpeg-4
|
# spec file for package ffmpeg-4
|
||||||
#
|
#
|
||||||
# Copyright (c) 2024 SUSE LLC
|
# Copyright (c) 2025 SUSE LLC
|
||||||
#
|
#
|
||||||
# All modifications and additions to the file contributed by third parties
|
# All modifications and additions to the file contributed by third parties
|
||||||
# remain the property of their copyright owners, unless otherwise agreed
|
# remain the property of their copyright owners, unless otherwise agreed
|
||||||
@ -57,7 +57,7 @@
|
|||||||
%bcond_with x265
|
%bcond_with x265
|
||||||
%bcond_with xvid
|
%bcond_with xvid
|
||||||
|
|
||||||
%if 0%{?suse_version} > 1500
|
%if 0%{?suse_version} > 1600
|
||||||
%bcond_without libaom
|
%bcond_without libaom
|
||||||
%bcond_without mysofa
|
%bcond_without mysofa
|
||||||
%bcond_without vidstab
|
%bcond_without vidstab
|
||||||
@ -73,6 +73,15 @@
|
|||||||
%bcond_without opencore
|
%bcond_without opencore
|
||||||
%bcond_without xvid
|
%bcond_without xvid
|
||||||
%else
|
%else
|
||||||
|
%if 0%{?suse_version} > 1500
|
||||||
|
%bcond_without mysofa
|
||||||
|
%bcond_without vidstab
|
||||||
|
%bcond_without codec2
|
||||||
|
%bcond_without rubberband
|
||||||
|
%bcond_without vulkan
|
||||||
|
%bcond_without amrwb
|
||||||
|
%bcond_without opencore
|
||||||
|
%else
|
||||||
%bcond_with libaom
|
%bcond_with libaom
|
||||||
%bcond_with mysofa
|
%bcond_with mysofa
|
||||||
%bcond_with vidstab
|
%bcond_with vidstab
|
||||||
@ -85,6 +94,7 @@
|
|||||||
%bcond_with zmq
|
%bcond_with zmq
|
||||||
%bcond_with vulkan
|
%bcond_with vulkan
|
||||||
%endif
|
%endif
|
||||||
|
%endif
|
||||||
|
|
||||||
%if 0%{?suse_version} >= 1500
|
%if 0%{?suse_version} >= 1500
|
||||||
%bcond_without zimg
|
%bcond_without zimg
|
||||||
@ -98,7 +108,7 @@
|
|||||||
%define _major_version 4
|
%define _major_version 4
|
||||||
%define _major_expected 5
|
%define _major_expected 5
|
||||||
Name: ffmpeg-4
|
Name: ffmpeg-4
|
||||||
Version: 4.4.4
|
Version: 4.4.5
|
||||||
Release: 0
|
Release: 0
|
||||||
Summary: Set of libraries for working with various multimedia formats
|
Summary: Set of libraries for working with various multimedia formats
|
||||||
License: GPL-3.0-or-later
|
License: GPL-3.0-or-later
|
||||||
@ -122,18 +132,16 @@ Patch5: soversion.patch
|
|||||||
Patch9: ffmpeg-4.4-CVE-2020-22046.patch
|
Patch9: ffmpeg-4.4-CVE-2020-22046.patch
|
||||||
Patch10: ffmpeg-chromium.patch
|
Patch10: ffmpeg-chromium.patch
|
||||||
Patch11: ffmpeg-libglslang-detection.patch
|
Patch11: ffmpeg-libglslang-detection.patch
|
||||||
Patch12: 0001-avcodec-libsvtav1-remove-compressed_ten_bit_format-a.patch
|
|
||||||
Patch13: 0001-avcodec-x86-mathops-clip-constants-used-with-shift-i.patch
|
|
||||||
Patch14: ffmpeg-glslang-cxx17.patch
|
Patch14: ffmpeg-glslang-cxx17.patch
|
||||||
Patch15: 0001-avutil-hwcontext-Don-t-assume-frames_uninit-is-reent.patch
|
Patch15: 0001-avutil-hwcontext-Don-t-assume-frames_uninit-is-reent.patch
|
||||||
Patch16: 0001-avfilter-vf_minterpolate-Check-pts-before-division.patch
|
|
||||||
Patch17: ffmpeg-CVE-2023-49502.patch
|
Patch17: ffmpeg-CVE-2023-49502.patch
|
||||||
Patch18: ffmpeg-CVE-2023-51793.patch
|
|
||||||
Patch19: 0001-avfilter-af_stereowiden-Check-length.patch
|
|
||||||
Patch20: ffmpeg-CVE-2023-50010.patch
|
|
||||||
Patch21: ffmpeg-4-CVE-2024-32230.patch
|
|
||||||
Patch22: ffmpeg-c99.patch
|
Patch22: ffmpeg-c99.patch
|
||||||
Patch23: 0001-libavcodec-arm-mlpdsp_armv5te-fix-label-format-to-wo.patch
|
Patch23: 0001-libavcodec-arm-mlpdsp_armv5te-fix-label-format-to-wo.patch
|
||||||
|
Patch24: ffmpeg-4-CVE-2024-12361.patch
|
||||||
|
Patch25: ffmpeg-4-CVE-2025-22919.patch
|
||||||
|
Patch26: ffmpeg-4-CVE-2025-0518.patch
|
||||||
|
Patch27: ffmpeg-4-CVE-2025-25473.patch
|
||||||
|
Patch28: ffmpeg-4-CVE-2025-22921.patch
|
||||||
BuildRequires: ladspa-devel
|
BuildRequires: ladspa-devel
|
||||||
BuildRequires: libgsm-devel
|
BuildRequires: libgsm-devel
|
||||||
BuildRequires: libmp3lame-devel
|
BuildRequires: libmp3lame-devel
|
||||||
|
@ -1,30 +0,0 @@
|
|||||||
commit e4d2666bdc3dbd177a81bbf428654a5f2fa3787a (20231224_CVE-2023-50010_e4d2666bdc3dbd177a81bbf428654a5f2fa3787a)
|
|
||||||
Author: Michael Niedermayer <michael@niedermayer.cc>
|
|
||||||
Date: Sun Dec 24 20:50:51 2023 +0100
|
|
||||||
References: CVE-2023-50010
|
|
||||||
References: https://bugzilla.opensuse.org/1172424
|
|
||||||
|
|
||||||
avfilter/vf_gradfun: Do not overread last line
|
|
||||||
|
|
||||||
The code works in steps of 2 lines and lacks support for odd height
|
|
||||||
Implementing odd height support is better but for now this fixes the
|
|
||||||
out of array access
|
|
||||||
|
|
||||||
Fixes: out of array access
|
|
||||||
Fixes: tickets/10702/poc6ffmpe
|
|
||||||
|
|
||||||
Found-by: Zeng Yunxiang
|
|
||||||
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
|
|
||||||
|
|
||||||
diff -Nura ffmpeg-4.4.4/libavfilter/vf_gradfun.c ffmpeg-4.4.4_new/libavfilter/vf_gradfun.c
|
|
||||||
--- ffmpeg-4.4.4/libavfilter/vf_gradfun.c 2023-04-13 02:01:50.000000000 +0800
|
|
||||||
+++ ffmpeg-4.4.4_new/libavfilter/vf_gradfun.c 2024-05-07 19:32:05.287848683 +0800
|
|
||||||
@@ -93,7 +93,7 @@
|
|
||||||
for (y = 0; y < r; y++)
|
|
||||||
ctx->blur_line(dc, buf + y * bstride, buf + (y - 1) * bstride, src + 2 * y * src_linesize, src_linesize, width / 2);
|
|
||||||
for (;;) {
|
|
||||||
- if (y < height - r) {
|
|
||||||
+ if (y + 1 < height - r) {
|
|
||||||
int mod = ((y + r) / 2) % r;
|
|
||||||
uint16_t *buf0 = buf + mod * bstride;
|
|
||||||
uint16_t *buf1 = buf + (mod ? mod - 1 : r - 1) * bstride;
|
|
@ -1,57 +0,0 @@
|
|||||||
From 0ecc1f0e48930723d7a467761b66850811c23e62
|
|
||||||
From: Michael Niedermayer <michael@niedermayer.cc>
|
|
||||||
Date: Fri Dec 22 12:31:35 2023 +0100
|
|
||||||
Subject: avfilter/vf_weave: Fix odd height handling
|
|
||||||
References: https://bugzilla.opensuse.org/1223272
|
|
||||||
References: CVE-2023-51793
|
|
||||||
|
|
||||||
Fixes: out of array access
|
|
||||||
Fixes: tickets/10743/poc10ffmpeg
|
|
||||||
|
|
||||||
Found-by: Zeng Yunxiang and Li Zeyuan
|
|
||||||
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
|
|
||||||
|
|
||||||
diff -Nura ffmpeg-4.4.4/libavfilter/vf_weave.c ffmpeg-4.4.4_new/libavfilter/vf_weave.c
|
|
||||||
--- ffmpeg-4.4.4/libavfilter/vf_weave.c 2023-04-13 02:01:50.000000000 +0800
|
|
||||||
+++ ffmpeg-4.4.4_new/libavfilter/vf_weave.c 2024-04-26 02:30:07.113807721 +0800
|
|
||||||
@@ -30,6 +30,7 @@
|
|
||||||
int double_weave;
|
|
||||||
int nb_planes;
|
|
||||||
int planeheight[4];
|
|
||||||
+ int outheight[4];
|
|
||||||
int linesize[4];
|
|
||||||
|
|
||||||
AVFrame *prev;
|
|
||||||
@@ -85,6 +86,9 @@
|
|
||||||
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;
|
|
||||||
@@ -110,19 +114,20 @@
|
|
||||||
const int height = s->planeheight[i];
|
|
||||||
const int start = (height * jobnr) / nb_jobs;
|
|
||||||
const int end = (height * (jobnr+1)) / nb_jobs;
|
|
||||||
+ const int compensation = 2*end > s->outheight[i];
|
|
||||||
|
|
||||||
av_image_copy_plane(out->data[i] + out->linesize[i] * field1 +
|
|
||||||
out->linesize[i] * start * 2,
|
|
||||||
out->linesize[i] * 2,
|
|
||||||
in->data[i] + start * in->linesize[i],
|
|
||||||
in->linesize[i],
|
|
||||||
- s->linesize[i], end - start);
|
|
||||||
+ s->linesize[i], end - start - compensation * field1);
|
|
||||||
av_image_copy_plane(out->data[i] + out->linesize[i] * field2 +
|
|
||||||
out->linesize[i] * start * 2,
|
|
||||||
out->linesize[i] * 2,
|
|
||||||
s->prev->data[i] + start * s->prev->linesize[i],
|
|
||||||
s->prev->linesize[i],
|
|
||||||
- s->linesize[i], end - start);
|
|
||||||
+ s->linesize[i], end - start - compensation * field2);
|
|
||||||
}
|
|
||||||
|
|
||||||
return 0;
|
|
Loading…
x
Reference in New Issue
Block a user