libsoup: fix CVE-2025-12105

Refer:
https://gitlab.gnome.org/GNOME/libsoup/-/merge_requests/481

(From OE-Core rev: caa6f192df558d5f46c8a0968f72f08c6e59df1d)

Signed-off-by: Changqing Li <changqing.li@windriver.com>
Signed-off-by: Steve Sakoman <steve@sakoman.com>
This commit is contained in:
Changqing Li 2025-12-23 15:20:20 +08:00 committed by Steve Sakoman
parent 33cffc4716
commit d35837e3cd
2 changed files with 35 additions and 0 deletions

View File

@ -0,0 +1,34 @@
From 465410f833e4288ad053b4e18d5fa6c3be3148e1 Mon Sep 17 00:00:00 2001
From: Eugene Mutavchi <Ievgen_Mutavchi@comcast.com>
Date: Fri, 10 Oct 2025 16:24:27 +0000
Subject: [PATCH] fix 'heap-use-after-free' caused by 'finishing' queue item
twice
CVE: CVE-2025-12105
Upstream-Status: Backport [https://gitlab.gnome.org/GNOME/libsoup/-/commit/9ba1243a24e442fa5ec44684617a4480027da960]
Signed-off-by: Changqing Li <changqing.li@windriver.com>
---
libsoup/soup-session.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/libsoup/soup-session.c b/libsoup/soup-session.c
index 5f2929f..b9f3e42 100644
--- a/libsoup/soup-session.c
+++ b/libsoup/soup-session.c
@@ -3093,8 +3093,10 @@ run_until_read_done (SoupMessage *msg,
if (soup_message_io_in_progress (msg))
soup_message_io_finished (msg);
item->paused = FALSE;
- item->state = SOUP_MESSAGE_FINISHING;
- soup_session_process_queue_item (item->session, item, NULL, FALSE);
+ if (item->state != SOUP_MESSAGE_FINISHED) {
+ item->state = SOUP_MESSAGE_FINISHING;
+ soup_session_process_queue_item (item->session, item, NULL, FALSE);
+ }
}
async_send_request_return_result (item, NULL, error);
}
--
2.34.1

View File

@ -45,6 +45,7 @@ SRC_URI = "${GNOME_MIRROR}/libsoup/${SHRT_VER}/libsoup-${PV}.tar.xz \
file://CVE-2025-46421.patch \ file://CVE-2025-46421.patch \
file://CVE-2025-4948.patch \ file://CVE-2025-4948.patch \
file://CVE-2025-4945.patch \ file://CVE-2025-4945.patch \
file://CVE-2025-12105.patch \
" "
SRC_URI[sha256sum] = "ebdf90cf3599c11acbb6818a9d9e3fc9d2c68e56eb829b93962972683e1bf7c8" SRC_URI[sha256sum] = "ebdf90cf3599c11acbb6818a9d9e3fc9d2c68e56eb829b93962972683e1bf7c8"