busybox/backport-CVE-2023-42363.patch
liuxu ff3c86d804 fix CVE-2023-42364 CVE-2023-42365 CVE-2023-42366 CVE-2023-42363
Signed-off-by: liuxu <liuxu156@huawei.com>
(cherry picked from commit 5bdec6d07aad71a4f8be4e43076a290b72c2cd96)
2024-06-19 14:50:50 +08:00

32 lines
904 B
Diff

From c8f999803ab38f97488091ea20d8d2e4967452d2 Mon Sep 17 00:00:00 2001
From: liuxu <liuxu156@huawei.com>
Date: Wed, 19 Jun 2024 11:44:32 +0800
Subject: [PATCH 4/4] awk: fix use after free (CVE-2023-42363)
backport from upstream:
https://git.alpinelinux.org/aports/plain/main/busybox/0001-awk-fix-use-after-free-CVE-2023-42363.patch
Signed-off-by: liuxu <liuxu156@huawei.com>
---
editors/awk.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/editors/awk.c b/editors/awk.c
index 7a73f04..8f146fc 100644
--- a/editors/awk.c
+++ b/editors/awk.c
@@ -2944,10 +2944,6 @@ static var *evaluate(node *op, var *res)
/* yes, remember where Fields[] is */
old_Fields_ptr = Fields;
}
- if (opinfo & OF_STR1) {
- L.s = getvar_s(L.v);
- debug_printf_eval("L.s:'%s'\n", L.s);
- }
if (opinfo & OF_NUM1) {
L_d = getvar_i(L.v);
debug_printf_eval("L_d:%f\n", L_d);
--
2.43.0