mirror of
https://git.yoctoproject.org/poky
synced 2026-01-29 21:08:42 +01:00
gstreamer1.0-plugins-base: patch CVE-2024-47542
Pick commits from: * https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8033 (From OE-Core rev: 8a0c3c92ec3bf150c0697d25c70ad149b2d82f0e) Signed-off-by: Peter Marko <peter.marko@siemens.com> Signed-off-by: Steve Sakoman <steve@sakoman.com>
This commit is contained in:
committed by
Steve Sakoman
parent
2187501065
commit
7e005c1f66
@@ -0,0 +1,64 @@
|
||||
From 537161868f36048571f400648ac7909f26c73d53 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Sebastian=20Dr=C3=B6ge?= <sebastian@centricular.com>
|
||||
Date: Thu, 26 Sep 2024 13:43:06 +0300
|
||||
Subject: [PATCH] id3v2: Don't try parsing extended header if not enough data
|
||||
is available
|
||||
|
||||
Thanks to Antonio Morales for finding and reporting the issue.
|
||||
|
||||
Fixes GHSL-2024-235
|
||||
Fixes https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/3842
|
||||
|
||||
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/8033>
|
||||
|
||||
CVE: CVE-2024-47542
|
||||
Upstream-Status: Backport [https://gitlab.freedesktop.org/gstreamer/gstreamer/-/commit/537161868f36048571f400648ac7909f26c73d53]
|
||||
Signed-off-by: Peter Marko <peter.marko@siemens.com>
|
||||
---
|
||||
gst-libs/gst/tag/id3v2.c | 11 ++++++++---
|
||||
1 file changed, 8 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/gst-libs/gst/tag/id3v2.c b/gst-libs/gst/tag/id3v2.c
|
||||
index 7db2cb7e12..70f975d133 100644
|
||||
--- a/gst-libs/gst/tag/id3v2.c
|
||||
+++ b/gst-libs/gst/tag/id3v2.c
|
||||
@@ -29,7 +29,7 @@
|
||||
|
||||
#define HANDLE_INVALID_SYNCSAFE
|
||||
|
||||
-static gboolean id3v2_frames_to_tag_list (ID3TagsWorking * work, guint size);
|
||||
+static gboolean id3v2_frames_to_tag_list (ID3TagsWorking * work);
|
||||
|
||||
#ifndef GST_DISABLE_GST_DEBUG
|
||||
|
||||
@@ -258,7 +258,7 @@ gst_tag_list_from_id3v2_tag (GstBuffer * buffer)
|
||||
GST_MEMDUMP ("ID3v2 tag (un-unsyced)", uu_data, work.hdr.frame_data_size);
|
||||
}
|
||||
|
||||
- id3v2_frames_to_tag_list (&work, work.hdr.frame_data_size);
|
||||
+ id3v2_frames_to_tag_list (&work);
|
||||
|
||||
g_free (uu_data);
|
||||
|
||||
@@ -440,12 +440,17 @@ id3v2_add_id3v2_frame_blob_to_taglist (ID3TagsWorking * work,
|
||||
}
|
||||
|
||||
static gboolean
|
||||
-id3v2_frames_to_tag_list (ID3TagsWorking * work, guint size)
|
||||
+id3v2_frames_to_tag_list (ID3TagsWorking * work)
|
||||
{
|
||||
guint frame_hdr_size;
|
||||
|
||||
/* Extended header if present */
|
||||
if (work->hdr.flags & ID3V2_HDR_FLAG_EXTHDR) {
|
||||
+ if (work->hdr.frame_data_size < 4) {
|
||||
+ GST_DEBUG ("Tag has no extended header data. Broken tag");
|
||||
+ return FALSE;
|
||||
+ }
|
||||
+
|
||||
work->hdr.ext_hdr_size = id3v2_read_synch_uint (work->hdr.frame_data, 4);
|
||||
|
||||
/* In id3v2.4.x the header size is the size of the *whole*
|
||||
--
|
||||
2.30.2
|
||||
|
||||
@@ -16,6 +16,7 @@ SRC_URI = "https://gstreamer.freedesktop.org/src/gst-plugins-base/gst-plugins-ba
|
||||
file://0007-oggstream-review-and-fix-per-format-min_packet_size.patch \
|
||||
file://0008-ssaparse-Search-for-closing-brace-after-opening-brac.patch \
|
||||
file://0009-ssaparse-Don-t-use-strstr-on-strings-that-are-potent.patch \
|
||||
file://0010-id3v2-Don-t-try-parsing-extended-header-if-not-enoug.patch \
|
||||
"
|
||||
SRC_URI[sha256sum] = "73cfadc3a6ffe77ed974cfd6fb391c605e4531f48db21dd6b9f42b8cb69bd8c1"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user