summaryrefslogtreecommitdiffstats
path: root/meta/recipes-multimedia/ffmpeg/ffmpeg
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-multimedia/ffmpeg/ffmpeg')
-rw-r--r--meta/recipes-multimedia/ffmpeg/ffmpeg/0001-lavf-srt-fix-build-fail-when-used-the-libsrt-1.4.1.patch52
-rw-r--r--meta/recipes-multimedia/ffmpeg/ffmpeg/0001-libavutil-include-assembly-with-full-path-from-sourc.patch97
-rw-r--r--meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2020-35964.patch75
-rw-r--r--meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2020-35965.patch35
-rw-r--r--meta/recipes-multimedia/ffmpeg/ffmpeg/mips64_cpu_detection.patch32
5 files changed, 0 insertions, 291 deletions
diff --git a/meta/recipes-multimedia/ffmpeg/ffmpeg/0001-lavf-srt-fix-build-fail-when-used-the-libsrt-1.4.1.patch b/meta/recipes-multimedia/ffmpeg/ffmpeg/0001-lavf-srt-fix-build-fail-when-used-the-libsrt-1.4.1.patch
deleted file mode 100644
index 7635c9196a..0000000000
--- a/meta/recipes-multimedia/ffmpeg/ffmpeg/0001-lavf-srt-fix-build-fail-when-used-the-libsrt-1.4.1.patch
+++ /dev/null
@@ -1,52 +0,0 @@
1From aebb72e025cbfbd4a6765354f6f565ad4ac89789 Mon Sep 17 00:00:00 2001
2From: Jun Zhao <barryjzhao@tencent.com>
3Date: Sun, 12 Jul 2020 05:48:48 +0800
4Subject: [PATCH] lavf/srt: fix build fail when used the libsrt 1.4.1
5
6lavf/srt: fix build fail when used the libsrt 1.4.1
7
8libsrt changed the:
9SRTO_SMOOTHER -> SRTO_CONGESTION
10SRTO_STRICTENC -> SRTO_ENFORCEDENCRYPTION
11and removed the front of deprecated options (SRTO_SMOOTHER/SRTO_STRICTENC)
12in the header, it's lead to build fail
13
14fix #8760
15
16Upstream-Status: Backport [https://github.com/FFmpeg/FFmpeg/commit/7c59e1b0f285cd7c7b35fcd71f49c5fd52cf9315]
17
18Signed-off-by: Jose Quaresma <quaresma.jose@gmail.com>
19Signed-off-by: Jun Zhao <barryjzhao@tencent.com>
20---
21 libavformat/libsrt.c | 8 ++++++++
22 1 file changed, 8 insertions(+)
23
24diff --git a/libavformat/libsrt.c b/libavformat/libsrt.c
25index 4de575b..4719ce0 100644
26--- a/libavformat/libsrt.c
27+++ b/libavformat/libsrt.c
28@@ -313,8 +313,12 @@ static int libsrt_set_options_pre(URLContext *h, int fd)
29 (s->pbkeylen >= 0 && libsrt_setsockopt(h, fd, SRTO_PBKEYLEN, "SRTO_PBKEYLEN", &s->pbkeylen, sizeof(s->pbkeylen)) < 0) ||
30 (s->passphrase && libsrt_setsockopt(h, fd, SRTO_PASSPHRASE, "SRTO_PASSPHRASE", s->passphrase, strlen(s->passphrase)) < 0) ||
31 #if SRT_VERSION_VALUE >= 0x010302
32+#if SRT_VERSION_VALUE >= 0x010401
33+ (s->enforced_encryption >= 0 && libsrt_setsockopt(h, fd, SRTO_ENFORCEDENCRYPTION, "SRTO_ENFORCEDENCRYPTION", &s->enforced_encryption, sizeof(s->enforced_encryption)) < 0) ||
34+#else
35 /* SRTO_STRICTENC == SRTO_ENFORCEDENCRYPTION (53), but for compatibility, we used SRTO_STRICTENC */
36 (s->enforced_encryption >= 0 && libsrt_setsockopt(h, fd, SRTO_STRICTENC, "SRTO_STRICTENC", &s->enforced_encryption, sizeof(s->enforced_encryption)) < 0) ||
37+#endif
38 (s->kmrefreshrate >= 0 && libsrt_setsockopt(h, fd, SRTO_KMREFRESHRATE, "SRTO_KMREFRESHRATE", &s->kmrefreshrate, sizeof(s->kmrefreshrate)) < 0) ||
39 (s->kmpreannounce >= 0 && libsrt_setsockopt(h, fd, SRTO_KMPREANNOUNCE, "SRTO_KMPREANNOUNCE", &s->kmpreannounce, sizeof(s->kmpreannounce)) < 0) ||
40 #endif
41@@ -333,7 +337,11 @@ static int libsrt_set_options_pre(URLContext *h, int fd)
42 (s->lossmaxttl >= 0 && libsrt_setsockopt(h, fd, SRTO_LOSSMAXTTL, "SRTO_LOSSMAXTTL", &s->lossmaxttl, sizeof(s->lossmaxttl)) < 0) ||
43 (s->minversion >= 0 && libsrt_setsockopt(h, fd, SRTO_MINVERSION, "SRTO_MINVERSION", &s->minversion, sizeof(s->minversion)) < 0) ||
44 (s->streamid && libsrt_setsockopt(h, fd, SRTO_STREAMID, "SRTO_STREAMID", s->streamid, strlen(s->streamid)) < 0) ||
45+#if SRT_VERSION_VALUE >= 0x010401
46+ (s->smoother && libsrt_setsockopt(h, fd, SRTO_CONGESTION, "SRTO_CONGESTION", s->smoother, strlen(s->smoother)) < 0) ||
47+#else
48 (s->smoother && libsrt_setsockopt(h, fd, SRTO_SMOOTHER, "SRTO_SMOOTHER", s->smoother, strlen(s->smoother)) < 0) ||
49+#endif
50 (s->messageapi >= 0 && libsrt_setsockopt(h, fd, SRTO_MESSAGEAPI, "SRTO_MESSAGEAPI", &s->messageapi, sizeof(s->messageapi)) < 0) ||
51 (s->payload_size >= 0 && libsrt_setsockopt(h, fd, SRTO_PAYLOADSIZE, "SRTO_PAYLOADSIZE", &s->payload_size, sizeof(s->payload_size)) < 0) ||
52 ((h->flags & AVIO_FLAG_WRITE) && libsrt_setsockopt(h, fd, SRTO_SENDER, "SRTO_SENDER", &yes, sizeof(yes)) < 0)) {
diff --git a/meta/recipes-multimedia/ffmpeg/ffmpeg/0001-libavutil-include-assembly-with-full-path-from-sourc.patch b/meta/recipes-multimedia/ffmpeg/ffmpeg/0001-libavutil-include-assembly-with-full-path-from-sourc.patch
deleted file mode 100644
index 3b503c49c9..0000000000
--- a/meta/recipes-multimedia/ffmpeg/ffmpeg/0001-libavutil-include-assembly-with-full-path-from-sourc.patch
+++ /dev/null
@@ -1,97 +0,0 @@
1From 24a58d70cbb3997e471366bd5afe54be9007bfb1 Mon Sep 17 00:00:00 2001
2From: Alexander Kanavin <alex.kanavin@gmail.com>
3Date: Tue, 10 Nov 2020 15:32:14 +0000
4Subject: [PATCH] libavutil: include assembly with full path from source root
5
6Otherwise nasm writes the full host-specific paths into .o
7output, which breaks binary reproducibility.
8
9Upstream-Status: Pending
10Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
11---
12 libavutil/x86/cpuid.asm | 2 +-
13 libavutil/x86/emms.asm | 2 +-
14 libavutil/x86/fixed_dsp.asm | 2 +-
15 libavutil/x86/float_dsp.asm | 2 +-
16 libavutil/x86/lls.asm | 2 +-
17 libavutil/x86/pixelutils.asm | 2 +-
18 6 files changed, 6 insertions(+), 6 deletions(-)
19
20diff --git a/libavutil/x86/cpuid.asm b/libavutil/x86/cpuid.asm
21index c3f7866..766f77f 100644
22--- a/libavutil/x86/cpuid.asm
23+++ b/libavutil/x86/cpuid.asm
24@@ -21,7 +21,7 @@
25 ;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
26 ;******************************************************************************
27
28-%include "x86util.asm"
29+%include "libavutil/x86/x86util.asm"
30
31 SECTION .text
32
33diff --git a/libavutil/x86/emms.asm b/libavutil/x86/emms.asm
34index 8611762..df84f22 100644
35--- a/libavutil/x86/emms.asm
36+++ b/libavutil/x86/emms.asm
37@@ -18,7 +18,7 @@
38 ;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
39 ;******************************************************************************
40
41-%include "x86util.asm"
42+%include "libavutil/x86/x86util.asm"
43
44 SECTION .text
45
46diff --git a/libavutil/x86/fixed_dsp.asm b/libavutil/x86/fixed_dsp.asm
47index 979dd5c..2f41185 100644
48--- a/libavutil/x86/fixed_dsp.asm
49+++ b/libavutil/x86/fixed_dsp.asm
50@@ -20,7 +20,7 @@
51 ;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
52 ;******************************************************************************
53
54-%include "x86util.asm"
55+%include "libavutil/x86/x86util.asm"
56
57 SECTION .text
58
59diff --git a/libavutil/x86/float_dsp.asm b/libavutil/x86/float_dsp.asm
60index 517fd63..b773e61 100644
61--- a/libavutil/x86/float_dsp.asm
62+++ b/libavutil/x86/float_dsp.asm
63@@ -20,7 +20,7 @@
64 ;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
65 ;******************************************************************************
66
67-%include "x86util.asm"
68+%include "libavutil/x86/x86util.asm"
69
70 SECTION_RODATA 32
71 pd_reverse: dd 7, 6, 5, 4, 3, 2, 1, 0
72diff --git a/libavutil/x86/lls.asm b/libavutil/x86/lls.asm
73index 317fba6..d2526d1 100644
74--- a/libavutil/x86/lls.asm
75+++ b/libavutil/x86/lls.asm
76@@ -20,7 +20,7 @@
77 ;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
78 ;******************************************************************************
79
80-%include "x86util.asm"
81+%include "libavutil/x86/x86util.asm"
82
83 SECTION .text
84
85diff --git a/libavutil/x86/pixelutils.asm b/libavutil/x86/pixelutils.asm
86index 36c57c5..8b45ead 100644
87--- a/libavutil/x86/pixelutils.asm
88+++ b/libavutil/x86/pixelutils.asm
89@@ -21,7 +21,7 @@
90 ;* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
91 ;******************************************************************************
92
93-%include "x86util.asm"
94+%include "libavutil/x86/x86util.asm"
95
96 SECTION .text
97
diff --git a/meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2020-35964.patch b/meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2020-35964.patch
deleted file mode 100644
index 6b96bd674f..0000000000
--- a/meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2020-35964.patch
+++ /dev/null
@@ -1,75 +0,0 @@
1From 27a99e2c7d450fef15594671eef4465c8a166bd7 Mon Sep 17 00:00:00 2001
2From: Michael Niedermayer <michael@niedermayer.cc>
3Date: Wed, 28 Oct 2020 20:11:54 +0100
4Subject: [PATCH] avformat/vividas: improve extradata packing checks in
5 track_header()
6
7Fixes: out of array accesses
8Fixes: 26622/clusterfuzz-testcase-minimized-ffmpeg_dem_VIVIDAS_fuzzer-6581200338288640
9
10Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
11Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
12
13Upstream-Status: Backport [https://github.com/FFmpeg/FFmpeg/commit/27a99e2c7d450fef15594671eef4465c8a166bd7]
14
15CVE: CVE-2020-35964
16
17Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
18Signed-off-by: Khairul Rohaizzat Jamaluddin <khairul.rohaizzat.jamaluddin@intel.com>
19---
20 libavformat/vividas.c | 12 ++++++------
21 1 file changed, 6 insertions(+), 6 deletions(-)
22
23diff --git a/libavformat/vividas.c b/libavformat/vividas.c
24index 83d0ed116787..46c66bf9a0ae 100644
25--- a/libavformat/vividas.c
26+++ b/libavformat/vividas.c
27@@ -28,6 +28,7 @@
28 * @sa http://wiki.multimedia.cx/index.php?title=Vividas_VIV
29 */
30
31+#include "libavutil/avassert.h"
32 #include "libavutil/intreadwrite.h"
33 #include "avio_internal.h"
34 #include "avformat.h"
35@@ -379,7 +380,7 @@ static int track_header(VividasDemuxContext *viv, AVFormatContext *s, uint8_t *
36
37 if (avio_tell(pb) < off) {
38 int num_data;
39- int xd_size = 0;
40+ int xd_size = 1;
41 int data_len[256];
42 int offset = 1;
43 uint8_t *p;
44@@ -393,10 +394,10 @@ static int track_header(VividasDemuxContext *viv, AVFormatContext *s, uint8_t *
45 return AVERROR_INVALIDDATA;
46 }
47 data_len[j] = len;
48- xd_size += len;
49+ xd_size += len + 1 + len/255;
50 }
51
52- ret = ff_alloc_extradata(st->codecpar, 64 + xd_size + xd_size / 255);
53+ ret = ff_alloc_extradata(st->codecpar, xd_size);
54 if (ret < 0)
55 return ret;
56
57@@ -405,9 +406,7 @@ static int track_header(VividasDemuxContext *viv, AVFormatContext *s, uint8_t *
58
59 for (j = 0; j < num_data - 1; j++) {
60 unsigned delta = av_xiphlacing(&p[offset], data_len[j]);
61- if (delta > data_len[j]) {
62- return AVERROR_INVALIDDATA;
63- }
64+ av_assert0(delta <= xd_size - offset);
65 offset += delta;
66 }
67
68@@ -418,6 +417,7 @@ static int track_header(VividasDemuxContext *viv, AVFormatContext *s, uint8_t *
69 av_freep(&st->codecpar->extradata);
70 break;
71 }
72+ av_assert0(data_len[j] <= xd_size - offset);
73 offset += data_len[j];
74 }
75
diff --git a/meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2020-35965.patch b/meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2020-35965.patch
deleted file mode 100644
index ddab8e9aca..0000000000
--- a/meta/recipes-multimedia/ffmpeg/ffmpeg/CVE-2020-35965.patch
+++ /dev/null
@@ -1,35 +0,0 @@
1From 3e5959b3457f7f1856d997261e6ac672bba49e8b Mon Sep 17 00:00:00 2001
2From: Michael Niedermayer <michael@niedermayer.cc>
3Date: Sat, 24 Oct 2020 22:21:48 +0200
4Subject: [PATCH] avcodec/exr: Check ymin vs. h
5
6Fixes: out of array access
7Fixes: 26532/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_EXR_fuzzer-5613925708857344
8Fixes: 27443/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_EXR_fuzzer-5631239813595136
9
10Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
11Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
12
13Upstream-Status: Backport [https://github.com/FFmpeg/FFmpeg/commit/3e5959b3457f7f1856d997261e6ac672bba49e8b]
14
15CVE: CVE-2020-35965
16
17Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
18Signed-off-by: Khairul Rohaizzat Jamaluddin <khairul.rohaizzat.jamaluddin@intel.com>
19---
20 libavcodec/exr.c | 2 +-
21 1 file changed, 1 insertion(+), 1 deletion(-)
22
23diff --git a/libavcodec/exr.c b/libavcodec/exr.c
24index e907c5c46401..8b701d1cd298 100644
25--- a/libavcodec/exr.c
26+++ b/libavcodec/exr.c
27@@ -1830,7 +1830,7 @@ static int decode_frame(AVCodecContext *avctx, void *data,
28 // Zero out the start if ymin is not 0
29 for (i = 0; i < planes; i++) {
30 ptr = picture->data[i];
31- for (y = 0; y < s->ymin; y++) {
32+ for (y = 0; y < FFMIN(s->ymin, s->h); y++) {
33 memset(ptr, 0, out_line_size);
34 ptr += picture->linesize[i];
35 }
diff --git a/meta/recipes-multimedia/ffmpeg/ffmpeg/mips64_cpu_detection.patch b/meta/recipes-multimedia/ffmpeg/ffmpeg/mips64_cpu_detection.patch
deleted file mode 100644
index 69429af8f0..0000000000
--- a/meta/recipes-multimedia/ffmpeg/ffmpeg/mips64_cpu_detection.patch
+++ /dev/null
@@ -1,32 +0,0 @@
1It will add -mips64r6 and -mips64r2 to cmdline which will
2cause conflicts
3
4in OE we user mips32r2 and mips64r2 for mips arch versions
5so there is no benefit of detecting it automatically by
6poking at tools especially in cross env
7
8Fixes errors like
9
10linking -mnan=2008 module with previous -mnan=legacy modules
11failed to merge target specific data of file
12
13-Khem
14Upstream-Status: Inappropriate [OE-Specific]
15
16Index: ffmpeg-3.1.1/configure
17===================================================================
18--- ffmpeg-3.1.1.orig/configure
19+++ ffmpeg-3.1.1/configure
20@@ -5220,12 +5220,9 @@ elif enabled mips; then
21
22 # Enable minimum ISA based on selected options
23 if enabled mips64; then
24- enabled mips64r6 && check_inline_asm_flags mips64r6 '"dlsa $0, $0, $0, 1"' '-mips64r6'
25 enabled mips64r2 && check_inline_asm_flags mips64r2 '"dext $0, $0, 0, 1"' '-mips64r2'
26 disabled mips64r6 && disabled mips64r2 && check_inline_asm_flags mips64r1 '"daddi $0, $0, 0"' '-mips64'
27 else
28- enabled mips32r6 && check_inline_asm_flags mips32r6 '"aui $0, $0, 0"' '-mips32r6'
29- enabled mips32r5 && check_inline_asm_flags mips32r5 '"eretnc"' '-mips32r5'
30 enabled mips32r2 && check_inline_asm_flags mips32r2 '"ext $0, $0, 0, 1"' '-mips32r2'
31 disabled mips32r6 && disabled mips32r5 && disabled mips32r2 && check_inline_asm_flags mips32r1 '"addi $0, $0, 0"' '-mips32'
32 fi