Skip to content

Commit af38d38

Browse files
[Medium] Patch systemd & systemd-bootstrap for CVE-2023-7008 (#13866)
1 parent 5bbe743 commit af38d38

File tree

6 files changed

+55
-11
lines changed

6 files changed

+55
-11
lines changed

SPECS/systemd/CVE-2023-7008.patch

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
From cbed44badf00e62b639e1cf04955080fcc8fc35a Mon Sep 17 00:00:00 2001
2+
From: akhila-guruju <[email protected]>
3+
Date: Thu, 22 May 2025 10:35:31 +0000
4+
Subject: [PATCH] Address CVE-2023-7008
5+
6+
Upstream Patch reference: https://github.com/systemd/systemd-stable/commit/4ada1290584745ab6643eece9e1756a8c0e079ca
7+
8+
---
9+
src/resolve/resolved-dns-transaction.c | 4 ++--
10+
1 file changed, 2 insertions(+), 2 deletions(-)
11+
12+
diff --git a/src/resolve/resolved-dns-transaction.c b/src/resolve/resolved-dns-transaction.c
13+
index 2ee45ff..5507fd9 100644
14+
--- a/src/resolve/resolved-dns-transaction.c
15+
+++ b/src/resolve/resolved-dns-transaction.c
16+
@@ -2781,7 +2781,7 @@ static int dns_transaction_requires_rrsig(DnsTransaction *t, DnsResourceRecord *
17+
if (r == 0)
18+
continue;
19+
20+
- return FLAGS_SET(t->answer_query_flags, SD_RESOLVED_AUTHENTICATED);
21+
+ return FLAGS_SET(dt->answer_query_flags, SD_RESOLVED_AUTHENTICATED);
22+
}
23+
24+
return true;
25+
@@ -2808,7 +2808,7 @@ static int dns_transaction_requires_rrsig(DnsTransaction *t, DnsResourceRecord *
26+
/* We found the transaction that was supposed to find the SOA RR for us. It was
27+
* successful, but found no RR for us. This means we are not at a zone cut. In this
28+
* case, we require authentication if the SOA lookup was authenticated too. */
29+
- return FLAGS_SET(t->answer_query_flags, SD_RESOLVED_AUTHENTICATED);
30+
+ return FLAGS_SET(dt->answer_query_flags, SD_RESOLVED_AUTHENTICATED);
31+
}
32+
33+
return true;
34+
--
35+
2.45.2
36+

SPECS/systemd/fix-journald-audit-logging.patch

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,4 @@ index a8e3b175ac49..ea535a27af7f 100644
2929
+ map_all_fields(p, map_fields_kernel, "_AUDIT_FIELD_", true, iovec, &n, n + N_IOVEC_AUDIT_FIELDS);
3030

3131
server_dispatch_message(s, iovec, n, ELEMENTSOF(iovec), NULL, NULL, LOG_NOTICE, 0);
32-
32+

SPECS/systemd/systemd-bootstrap.spec

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Summary: Bootstrap version of systemd. Workaround for systemd circular dependency.
22
Name: systemd-bootstrap
33
Version: 250.3
4-
Release: 12%{?dist}
4+
Release: 13%{?dist}
55
License: LGPLv2+ AND GPLv2+ AND MIT
66
Vendor: Microsoft Corporation
77
Distribution: Mariner
@@ -25,6 +25,7 @@ Patch3: CVE-2022-3821.patch
2525
Patch4: CVE-2022-45873.patch
2626
Patch5: backport-helper-util-macros.patch
2727
Patch6: CVE-2022-4415.patch
28+
Patch7: CVE-2023-7008.patch
2829
BuildRequires: docbook-dtd-xml
2930
BuildRequires: docbook-style-xsl
3031
BuildRequires: gettext
@@ -246,6 +247,9 @@ fi
246247
%{_datadir}/pkgconfig/udev.pc
247248

248249
%changelog
250+
* Fri May 23 2025 Akhila Guruju <[email protected]> - 250.3-13
251+
- Patch CVE-2023-7008
252+
249253
* Mon Mar 13 2023 Nicolas Guibourge <[email protected]> - 250.3-12
250254
- Add patch for CVE-2022-4415
251255
- Add patch backport-helper-util-macros.patch to backport needed macros for CVE-2022-4415.patch

SPECS/systemd/systemd.spec

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
Summary: Systemd-250
22
Name: systemd
33
Version: 250.3
4-
Release: 21%{?dist}
4+
Release: 22%{?dist}
55
License: LGPLv2+ AND GPLv2+ AND MIT
66
Vendor: Microsoft Corporation
77
Distribution: Mariner
@@ -31,6 +31,7 @@ Patch8: serve-stale-0002-resolved-Initialize-until_valid-while-storing-n
3131
Patch9: mariner-2-do-not-default-zstd-journal-files-for-backwards-compatibility.patch
3232
Patch10: mariner-2-force-use-of-lz4-for-coredump.patch
3333
Patch11: networkd-default-use-domains.patch
34+
Patch12: CVE-2023-7008.patch
3435
BuildRequires: audit-devel
3536
BuildRequires: cryptsetup-devel
3637
BuildRequires: docbook-dtd-xml
@@ -289,6 +290,9 @@ fi
289290
%files lang -f %{name}.lang
290291

291292
%changelog
293+
* Thu May 22 2025 Akhila Guruju <[email protected]> - 250.3-22
294+
- Patch CVE-2023-7008
295+
292296
* Mon Apr 08 2024 Henry Li <[email protected]> - 250.3-21
293297
- Add patch to allow configurability of "UseDomains=" for networkd
294298

toolkit/resources/manifests/package/toolchain_aarch64.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -554,10 +554,10 @@ sqlite-devel-3.39.2-3.cm2.aarch64.rpm
554554
sqlite-libs-3.39.2-3.cm2.aarch64.rpm
555555
swig-4.0.2-3.cm2.aarch64.rpm
556556
swig-debuginfo-4.0.2-3.cm2.aarch64.rpm
557-
systemd-bootstrap-250.3-12.cm2.aarch64.rpm
558-
systemd-bootstrap-debuginfo-250.3-12.cm2.aarch64.rpm
559-
systemd-bootstrap-devel-250.3-12.cm2.aarch64.rpm
560-
systemd-bootstrap-rpm-macros-250.3-12.cm2.noarch.rpm
557+
systemd-bootstrap-250.3-13.cm2.aarch64.rpm
558+
systemd-bootstrap-debuginfo-250.3-13.cm2.aarch64.rpm
559+
systemd-bootstrap-devel-250.3-13.cm2.aarch64.rpm
560+
systemd-bootstrap-rpm-macros-250.3-13.cm2.noarch.rpm
561561
tar-1.34-3.cm2.aarch64.rpm
562562
tar-debuginfo-1.34-3.cm2.aarch64.rpm
563563
tdnf-3.5.2-4.cm2.aarch64.rpm

toolkit/resources/manifests/package/toolchain_x86_64.txt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -560,10 +560,10 @@ sqlite-devel-3.39.2-3.cm2.x86_64.rpm
560560
sqlite-libs-3.39.2-3.cm2.x86_64.rpm
561561
swig-4.0.2-3.cm2.x86_64.rpm
562562
swig-debuginfo-4.0.2-3.cm2.x86_64.rpm
563-
systemd-bootstrap-250.3-12.cm2.x86_64.rpm
564-
systemd-bootstrap-debuginfo-250.3-12.cm2.x86_64.rpm
565-
systemd-bootstrap-devel-250.3-12.cm2.x86_64.rpm
566-
systemd-bootstrap-rpm-macros-250.3-12.cm2.noarch.rpm
563+
systemd-bootstrap-250.3-13.cm2.x86_64.rpm
564+
systemd-bootstrap-debuginfo-250.3-13.cm2.x86_64.rpm
565+
systemd-bootstrap-devel-250.3-13.cm2.x86_64.rpm
566+
systemd-bootstrap-rpm-macros-250.3-13.cm2.noarch.rpm
567567
tar-1.34-3.cm2.x86_64.rpm
568568
tar-debuginfo-1.34-3.cm2.x86_64.rpm
569569
tdnf-3.5.2-4.cm2.x86_64.rpm

0 commit comments

Comments
 (0)