File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ From 5cf8b332429a1dd9afef3337bae92aeddaeff993 Mon Sep 17 00:00:00 2001
2+ From: Valery Ushakov <uwe@stderr.spb.ru>
3+ Date: Wed, 24 Jan 2024 22:24:41 +0300
4+ Subject: [PATCH] awk.c: fix CVE-2023-42366 (bug #15874)
5+
6+ Make sure we don't read past the end of the string in next_token()
7+ when backslash is the last character in an (invalid) regexp.
8+ ---
9+ editors/awk.c | 6 ++++--
10+ 1 file changed, 4 insertions(+), 2 deletions(-)
11+
12+ diff --git a/editors/awk.c b/editors/awk.c
13+ index 728ee8685..be48df7c7 100644
14+ --- a/editors/awk.c
15+ +++ b/editors/awk.c
16+ @@ -1165,9 +1165,11 @@ static uint32_t next_token(uint32_t expected)
17+ s[-1] = bb_process_escape_sequence((const char **)&pp);
18+ if (*p == '\\')
19+ *s++ = '\\';
20+ - if (pp == p)
21+ + if (pp == p) {
22+ + if (*p == '\0')
23+ + syntax_error(EMSG_UNEXP_EOS);
24+ *s++ = *p++;
25+ - else
26+ + } else
27+ p = pp;
28+ }
29+ }
30+ - -
31+ 2.34.1
32+
Original file line number Diff line number Diff line change 11Summary: Statically linked binary providing simplified versions of system commands
22Name: busybox
33Version: 1.35.0
4- Release: 11 %{?dist }
4+ Release: 12 %{?dist }
55License: GPLv2
66Vendor: Microsoft Corporation
77Distribution: Mariner
@@ -18,9 +18,10 @@ Patch5: ash-fix-use-after-free-in-bash-pattern-substitution.patch
1818Patch6: selinux-copy-file.patch
1919Patch7: selinux-cp-a.patch
2020Patch8: CVE-2021-42380.patch
21- # Also Fixes CVE-2023-42364
2221Patch9: CVE-2023-42363.patch
22+ # Also Fixes CVE-2023-42364
2323Patch10: CVE-2023-42365.patch
24+ Patch11: CVE-2023-42366.patch
2425BuildRequires: gcc
2526BuildRequires: glibc-static >= 2.35-7%{?dist }
2627BuildRequires: libselinux-devel >= 1.27.7-2
@@ -100,6 +101,9 @@ install -m 644 docs/busybox.petitboot.1 %{buildroot}/%{_mandir}/man1/busybox.pet
100101%{_mandir }/man1/busybox.petitboot.1.gz
101102
102103%changelog
104+ * Fri Nov 15 2024 Ankita Pareek <ankitapareek@microsoft.com> - 1.35.0-12
105+ - Address CVE-2023-42366
106+
103107* Tue Aug 13 2024 Suresh Thelkar <sthelkar@microsoft.com> - 1.35.0-11
104108- Address CVE-2021-42380, CVE-2023-42363, CVE-2023-42364 & CVE-2023-42365
105109
You can’t perform that action at this time.
0 commit comments