summaryrefslogtreecommitdiffstats
path: root/meta-networking/recipes-extended
diff options
context:
space:
mode:
Diffstat (limited to 'meta-networking/recipes-extended')
-rw-r--r--meta-networking/recipes-extended/corosync/corosync/CVE-2025-30472.patch69
-rw-r--r--meta-networking/recipes-extended/corosync/corosync_3.1.9.bb (renamed from meta-networking/recipes-extended/corosync/corosync_3.1.6.bb)19
-rw-r--r--meta-networking/recipes-extended/dlm/dlm_4.2.0.bb3
-rw-r--r--meta-networking/recipes-extended/kronosnet/kronosnet_1.24.bb1
-rw-r--r--meta-networking/recipes-extended/tgt/tgt_1.0.90.bb7
5 files changed, 82 insertions, 17 deletions
diff --git a/meta-networking/recipes-extended/corosync/corosync/CVE-2025-30472.patch b/meta-networking/recipes-extended/corosync/corosync/CVE-2025-30472.patch
new file mode 100644
index 0000000000..9b36dbe3fb
--- /dev/null
+++ b/meta-networking/recipes-extended/corosync/corosync/CVE-2025-30472.patch
@@ -0,0 +1,69 @@
1From 7839990f9cdf34e55435ed90109e82709032466a Mon Sep 17 00:00:00 2001
2From: Jan Friesse <jfriesse@redhat.com>
3Date: Mon, 24 Mar 2025 12:05:08 +0100
4Subject: [PATCH] totemsrp: Check size of orf_token msg
5
6orf_token message is stored into preallocated array on endian convert
7so carefully crafted malicious message can lead to crash of corosync.
8
9Solution is to check message size beforehand.
10
11Signed-off-by: Jan Friesse <jfriesse@redhat.com>
12Reviewed-by: Christine Caulfield <ccaulfie@redhat.com>
13
14CVE: CVE-2025-30472
15Upstream-Status: Backport [https://github.com/corosync/corosync/commits/7839990f9cdf34e55435ed90109e82709032466a]
16Signed-off-by: Peter Marko <peter.marko@siemens.com>
17---
18 exec/totemsrp.c | 18 +++++++++++++++++-
19 1 file changed, 17 insertions(+), 1 deletion(-)
20
21diff --git a/exec/totemsrp.c b/exec/totemsrp.c
22index 962d0e2a..364528ce 100644
23--- a/exec/totemsrp.c
24+++ b/exec/totemsrp.c
25@@ -3679,12 +3679,20 @@ static int check_orf_token_sanity(
26 const struct totemsrp_instance *instance,
27 const void *msg,
28 size_t msg_len,
29+ size_t max_msg_len,
30 int endian_conversion_needed)
31 {
32 int rtr_entries;
33 const struct orf_token *token = (const struct orf_token *)msg;
34 size_t required_len;
35
36+ if (msg_len > max_msg_len) {
37+ log_printf (instance->totemsrp_log_level_security,
38+ "Received orf_token message is too long... ignoring.");
39+
40+ return (-1);
41+ }
42+
43 if (msg_len < sizeof(struct orf_token)) {
44 log_printf (instance->totemsrp_log_level_security,
45 "Received orf_token message is too short... ignoring.");
46@@ -3698,6 +3706,13 @@ static int check_orf_token_sanity(
47 rtr_entries = token->rtr_list_entries;
48 }
49
50+ if (rtr_entries > RETRANSMIT_ENTRIES_MAX) {
51+ log_printf (instance->totemsrp_log_level_security,
52+ "Received orf_token message rtr_entries is corrupted... ignoring.");
53+
54+ return (-1);
55+ }
56+
57 required_len = sizeof(struct orf_token) + rtr_entries * sizeof(struct rtr_item);
58 if (msg_len < required_len) {
59 log_printf (instance->totemsrp_log_level_security,
60@@ -3868,7 +3883,8 @@ static int message_handler_orf_token (
61 "Time since last token %0.4f ms", tv_diff / (float)QB_TIME_NS_IN_MSEC);
62 #endif
63
64- if (check_orf_token_sanity(instance, msg, msg_len, endian_conversion_needed) == -1) {
65+ if (check_orf_token_sanity(instance, msg, msg_len, sizeof(token_storage),
66+ endian_conversion_needed) == -1) {
67 return (0);
68 }
69
diff --git a/meta-networking/recipes-extended/corosync/corosync_3.1.6.bb b/meta-networking/recipes-extended/corosync/corosync_3.1.9.bb
index 8fca576614..1699701c9d 100644
--- a/meta-networking/recipes-extended/corosync/corosync_3.1.6.bb
+++ b/meta-networking/recipes-extended/corosync/corosync_3.1.9.bb
@@ -5,16 +5,17 @@ HOMEPAGE = "http://corosync.github.io/corosync/"
5 5
6SECTION = "base" 6SECTION = "base"
7 7
8inherit autotools pkgconfig systemd 8inherit autotools pkgconfig systemd github-releases
9 9
10SRC_URI = "https://github.com/${BPN}/${BPN}/releases/download/v${PV}/${BP}.tar.gz \ 10SRC_URI = "${GITHUB_BASE_URI}/download/v${PV}/${BP}.tar.gz \
11 file://corosync.conf \ 11 file://corosync.conf \
12 file://CVE-2025-30472.patch \
12 " 13 "
13SRC_URI[sha256sum] = "ca6ed32b4d7f33ed614afce8760fe58d0de92c68b575d4969ebacd892f3d1e27" 14SRC_URI[sha256sum] = "203354bbddee1a97b3c50a076eae89c635f406dd674ccaefc94bb9092acd9535"
14UPSTREAM_CHECK_REGEX = "(?P<pver>\d+\.(?!99)\d+(\.\d+)+)" 15UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+(\.\d+)+)"
15 16
16LICENSE = "BSD-3-Clause" 17LICENSE = "BSD-3-Clause"
17LIC_FILES_CHKSUM = "file://LICENSE;md5=a85eb4ce24033adb6088dd1d6ffc5e5d" 18LIC_FILES_CHKSUM = "file://LICENSE;md5=d9c2cca5d3448c43e52a399ad611658a"
18 19
19DEPENDS = "groff-native nss libqb kronosnet" 20DEPENDS = "groff-native nss libqb kronosnet"
20 21
@@ -34,13 +35,8 @@ PACKAGECONFIG[systemd] = "--enable-systemd --with-systemddir=${systemd_system_un
34EXTRA_OECONF = "ac_cv_path_BASHPATH=${base_bindir}/bash ap_cv_cc_pie=no" 35EXTRA_OECONF = "ac_cv_path_BASHPATH=${base_bindir}/bash ap_cv_cc_pie=no"
35EXTRA_OEMAKE = "tmpfilesdir_DATA=" 36EXTRA_OEMAKE = "tmpfilesdir_DATA="
36 37
37#do_configure:prepend() {
38# ( cd ${S}
39# ${S}/autogen.sh )
40#}
41
42do_install:append() { 38do_install:append() {
43 install -D -m 0644 ${WORKDIR}/corosync.conf ${D}${sysconfdir}/corosync/corosync.conf.example 39 install -D -m 0644 ${UNPACKDIR}/corosync.conf ${D}${sysconfdir}/corosync/corosync.conf.example
44 install -d ${D}${sysconfdir}/sysconfig/ 40 install -d ${D}${sysconfdir}/sysconfig/
45 install -m 0644 ${S}/init/corosync.sysconfig.example ${D}${sysconfdir}/sysconfig/corosync 41 install -m 0644 ${S}/init/corosync.sysconfig.example ${D}${sysconfdir}/sysconfig/corosync
46 install -m 0644 ${S}/tools/corosync-notifyd.sysconfig.example ${D}${sysconfdir}/sysconfig/corosync-notifyd 42 install -m 0644 ${S}/tools/corosync-notifyd.sysconfig.example ${D}${sysconfdir}/sysconfig/corosync-notifyd
@@ -59,5 +55,6 @@ do_install:append() {
59 55
60RDEPENDS:${PN} += "bash ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'sysvinit-pidof', 'procps', d)}" 56RDEPENDS:${PN} += "bash ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'sysvinit-pidof', 'procps', d)}"
61 57
58FILES:${PN} += "${datadir}/dbus-1"
62FILES:${PN}-dbg += "${libexecdir}/lcrso/.debug" 59FILES:${PN}-dbg += "${libexecdir}/lcrso/.debug"
63FILES:${PN}-doc += "${datadir}/snmp/mibs/COROSYNC-MIB.txt" 60FILES:${PN}-doc += "${datadir}/snmp/mibs/COROSYNC-MIB.txt"
diff --git a/meta-networking/recipes-extended/dlm/dlm_4.2.0.bb b/meta-networking/recipes-extended/dlm/dlm_4.2.0.bb
index ee006efe28..b7966d7f12 100644
--- a/meta-networking/recipes-extended/dlm/dlm_4.2.0.bb
+++ b/meta-networking/recipes-extended/dlm/dlm_4.2.0.bb
@@ -21,7 +21,7 @@ UPSTREAM_CHECK_REGEX = "dlm-(?P<pver>\d+(\.\d+)+)"
21LICENSE = "LGPL-2.0-or-later & GPL-2.0-only & GPL-2.0-or-later" 21LICENSE = "LGPL-2.0-or-later & GPL-2.0-only & GPL-2.0-or-later"
22LIC_FILES_CHKSUM = "file://README.license;md5=8f0bbcdd678df1bce9863492b6c8832d" 22LIC_FILES_CHKSUM = "file://README.license;md5=8f0bbcdd678df1bce9863492b6c8832d"
23 23
24S = "${WORKDIR}/dlm-dlm-${PV}" 24S = "${UNPACKDIR}/dlm-dlm-${PV}"
25 25
26DEPENDS += "corosync" 26DEPENDS += "corosync"
27 27
@@ -37,6 +37,7 @@ SYSTEMD_AUTO_ENABLE = "enable"
37export EXTRA_OEMAKE = "" 37export EXTRA_OEMAKE = ""
38 38
39CFPROTECTION ?= "-fcf-protection=full" 39CFPROTECTION ?= "-fcf-protection=full"
40CFPROTECTION:riscv32 = ""
40CFPROTECTION:riscv64 = "" 41CFPROTECTION:riscv64 = ""
41CFPROTECTION:arm = "" 42CFPROTECTION:arm = ""
42CFPROTECTION:aarch64 = "" 43CFPROTECTION:aarch64 = ""
diff --git a/meta-networking/recipes-extended/kronosnet/kronosnet_1.24.bb b/meta-networking/recipes-extended/kronosnet/kronosnet_1.24.bb
index cbd5e7a0fd..06b2fa4d2d 100644
--- a/meta-networking/recipes-extended/kronosnet/kronosnet_1.24.bb
+++ b/meta-networking/recipes-extended/kronosnet/kronosnet_1.24.bb
@@ -20,7 +20,6 @@ UPSTREAM_CHECK_URI = "https://github.com/kronosnet/kronosnet/releases"
20 20
21inherit autotools pkgconfig 21inherit autotools pkgconfig
22 22
23S = "${WORKDIR}/git"
24 23
25# libknet/transport_udp.c:326:48: error: comparison of integers of different signs: 'unsigned long' and 'int' [-Werror,-Wsign-compare] 24# libknet/transport_udp.c:326:48: error: comparison of integers of different signs: 'unsigned long' and 'int' [-Werror,-Wsign-compare]
26# for (cmsg = CMSG_FIRSTHDR(&msg);cmsg; cmsg = CMSG_NXTHDR(&msg, cmsg)) { 25# for (cmsg = CMSG_FIRSTHDR(&msg);cmsg; cmsg = CMSG_NXTHDR(&msg, cmsg)) {
diff --git a/meta-networking/recipes-extended/tgt/tgt_1.0.90.bb b/meta-networking/recipes-extended/tgt/tgt_1.0.90.bb
index 35995f7876..a110d556a3 100644
--- a/meta-networking/recipes-extended/tgt/tgt_1.0.90.bb
+++ b/meta-networking/recipes-extended/tgt/tgt_1.0.90.bb
@@ -17,7 +17,6 @@ SRC_URI += "file://tgtd.init \
17 file://tgtd \ 17 file://tgtd \
18" 18"
19 19
20S = "${WORKDIR}/git"
21 20
22CONFFILES:${PN} += "${sysconfdir}/tgt/targets.conf" 21CONFFILES:${PN} += "${sysconfdir}/tgt/targets.conf"
23 22
@@ -39,12 +38,12 @@ do_install() {
39 38
40 if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then 39 if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
41 install -d ${D}${sysconfdir}/init.d 40 install -d ${D}${sysconfdir}/init.d
42 install -m 0755 ${WORKDIR}/tgtd.init ${D}${sysconfdir}/init.d/tgtd 41 install -m 0755 ${UNPACKDIR}/tgtd.init ${D}${sysconfdir}/init.d/tgtd
43 elif ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then 42 elif ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
44 install -d ${D}${systemd_unitdir}/system 43 install -d ${D}${systemd_unitdir}/system
45 install -m 0644 ${WORKDIR}/tgtd.service ${D}${systemd_unitdir}/system/tgtd.service 44 install -m 0644 ${UNPACKDIR}/tgtd.service ${D}${systemd_unitdir}/system/tgtd.service
46 install -d ${D}${sysconfdir}/sysconfig 45 install -d ${D}${sysconfdir}/sysconfig
47 install -m 0644 ${WORKDIR}/tgtd ${D}${sysconfdir}/sysconfig/tgtd 46 install -m 0644 ${UNPACKDIR}/tgtd ${D}${sysconfdir}/sysconfig/tgtd
48 sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/tgtd.service 47 sed -i -e 's,@SBINDIR@,${sbindir},g' ${D}${systemd_unitdir}/system/tgtd.service
49 sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' ${D}${systemd_unitdir}/system/tgtd.service 48 sed -i -e 's,@BASE_BINDIR@,${base_bindir},g' ${D}${systemd_unitdir}/system/tgtd.service
50 sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/tgtd.service 49 sed -i -e 's,@SYSCONFDIR@,${sysconfdir},g' ${D}${systemd_unitdir}/system/tgtd.service