diff options
| -rw-r--r-- | meta/recipes-core/busybox/busybox-inittab_1.36.0.bb (renamed from meta/recipes-core/busybox/busybox-inittab_1.35.0.bb) | 0 | ||||
| -rw-r--r-- | meta/recipes-core/busybox/busybox/0001-devmem-add-128-bit-width.patch | 128 | ||||
| -rw-r--r-- | meta/recipes-core/busybox/busybox/CVE-2022-30065.patch | 29 | ||||
| -rw-r--r-- | meta/recipes-core/busybox/busybox/defconfig | 10 | ||||
| -rw-r--r-- | meta/recipes-core/busybox/busybox/recognize_connmand.patch | 10 | ||||
| -rw-r--r-- | meta/recipes-core/busybox/busybox/sha1sum.cfg | 2 | ||||
| -rw-r--r-- | meta/recipes-core/busybox/busybox/sha256sum.cfg | 1 | ||||
| -rw-r--r-- | meta/recipes-core/busybox/busybox_1.36.0.bb (renamed from meta/recipes-core/busybox/busybox_1.35.0.bb) | 4 |
8 files changed, 17 insertions, 167 deletions
diff --git a/meta/recipes-core/busybox/busybox-inittab_1.35.0.bb b/meta/recipes-core/busybox/busybox-inittab_1.36.0.bb index 868d7a230f..868d7a230f 100644 --- a/meta/recipes-core/busybox/busybox-inittab_1.35.0.bb +++ b/meta/recipes-core/busybox/busybox-inittab_1.36.0.bb | |||
diff --git a/meta/recipes-core/busybox/busybox/0001-devmem-add-128-bit-width.patch b/meta/recipes-core/busybox/busybox/0001-devmem-add-128-bit-width.patch deleted file mode 100644 index 985e2bf1d9..0000000000 --- a/meta/recipes-core/busybox/busybox/0001-devmem-add-128-bit-width.patch +++ /dev/null | |||
| @@ -1,128 +0,0 @@ | |||
| 1 | From d432049f288c9acdc4a7caa729c68ceba3c5dca1 Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Aaro Koskinen <aaro.koskinen@nokia.com> | ||
| 3 | Date: Thu, 25 Aug 2022 18:47:02 +0300 | ||
| 4 | Subject: [PATCH] devmem: add 128-bit width | ||
| 5 | |||
| 6 | Add 128-bit width if the compiler provides the needed type. | ||
| 7 | |||
| 8 | function old new delta | ||
| 9 | devmem_main 405 464 +59 | ||
| 10 | .rodata 109025 109043 +18 | ||
| 11 | ------------------------------------------------------------------------------ | ||
| 12 | (add/remove: 0/0 grow/shrink: 2/0 up/down: 77/0) Total: 77 bytes | ||
| 13 | |||
| 14 | Upstream-Status: Backport [https://git.busybox.net/busybox/commit/?id=d432049f288c9acdc4a7caa729c68ceba3c5dca1] | ||
| 15 | |||
| 16 | Signed-off-by: Aaro Koskinen <aaro.koskinen@nokia.com> | ||
| 17 | Signed-off-by: Aaro Koskinen <aaro.koskinen@iki.fi> | ||
| 18 | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com> | ||
| 19 | Signed-off-by: Mingli Yu <mingli.yu@windriver.com> | ||
| 20 | --- | ||
| 21 | miscutils/devmem.c | 68 ++++++++++++++++++++++++++++++---------------- | ||
| 22 | 1 file changed, 44 insertions(+), 24 deletions(-) | ||
| 23 | |||
| 24 | diff --git a/miscutils/devmem.c b/miscutils/devmem.c | ||
| 25 | index f9f0276bc..f21621bd6 100644 | ||
| 26 | --- a/miscutils/devmem.c | ||
| 27 | +++ b/miscutils/devmem.c | ||
| 28 | @@ -29,7 +29,6 @@ int devmem_main(int argc UNUSED_PARAM, char **argv) | ||
| 29 | { | ||
| 30 | void *map_base, *virt_addr; | ||
| 31 | uint64_t read_result; | ||
| 32 | - uint64_t writeval = writeval; /* for compiler */ | ||
| 33 | off_t target; | ||
| 34 | unsigned page_size, mapped_size, offset_in_page; | ||
| 35 | int fd; | ||
| 36 | @@ -64,9 +63,6 @@ int devmem_main(int argc UNUSED_PARAM, char **argv) | ||
| 37 | width = strchrnul(bhwl, (argv[2][0] | 0x20)) - bhwl; | ||
| 38 | width = sizes[width]; | ||
| 39 | } | ||
| 40 | - /* VALUE */ | ||
| 41 | - if (argv[3]) | ||
| 42 | - writeval = bb_strtoull(argv[3], NULL, 0); | ||
| 43 | } else { /* argv[2] == NULL */ | ||
| 44 | /* make argv[3] to be a valid thing to fetch */ | ||
| 45 | argv--; | ||
| 46 | @@ -96,28 +92,46 @@ int devmem_main(int argc UNUSED_PARAM, char **argv) | ||
| 47 | virt_addr = (char*)map_base + offset_in_page; | ||
| 48 | |||
| 49 | if (!argv[3]) { | ||
| 50 | - switch (width) { | ||
| 51 | - case 8: | ||
| 52 | - read_result = *(volatile uint8_t*)virt_addr; | ||
| 53 | - break; | ||
| 54 | - case 16: | ||
| 55 | - read_result = *(volatile uint16_t*)virt_addr; | ||
| 56 | - break; | ||
| 57 | - case 32: | ||
| 58 | - read_result = *(volatile uint32_t*)virt_addr; | ||
| 59 | - break; | ||
| 60 | - case 64: | ||
| 61 | - read_result = *(volatile uint64_t*)virt_addr; | ||
| 62 | - break; | ||
| 63 | - default: | ||
| 64 | - bb_simple_error_msg_and_die("bad width"); | ||
| 65 | +#ifdef __SIZEOF_INT128__ | ||
| 66 | + if (width == 128) { | ||
| 67 | + unsigned __int128 rd = | ||
| 68 | + *(volatile unsigned __int128 *)virt_addr; | ||
| 69 | + printf("0x%016llX%016llX\n", | ||
| 70 | + (unsigned long long)(uint64_t)(rd >> 64), | ||
| 71 | + (unsigned long long)(uint64_t)rd | ||
| 72 | + ); | ||
| 73 | + } else | ||
| 74 | +#endif | ||
| 75 | + { | ||
| 76 | + switch (width) { | ||
| 77 | + case 8: | ||
| 78 | + read_result = *(volatile uint8_t*)virt_addr; | ||
| 79 | + break; | ||
| 80 | + case 16: | ||
| 81 | + read_result = *(volatile uint16_t*)virt_addr; | ||
| 82 | + break; | ||
| 83 | + case 32: | ||
| 84 | + read_result = *(volatile uint32_t*)virt_addr; | ||
| 85 | + break; | ||
| 86 | + case 64: | ||
| 87 | + read_result = *(volatile uint64_t*)virt_addr; | ||
| 88 | + break; | ||
| 89 | + default: | ||
| 90 | + bb_simple_error_msg_and_die("bad width"); | ||
| 91 | + } | ||
| 92 | +// printf("Value at address 0x%"OFF_FMT"X (%p): 0x%llX\n", | ||
| 93 | +// target, virt_addr, | ||
| 94 | +// (unsigned long long)read_result); | ||
| 95 | + /* Zero-padded output shows the width of access just done */ | ||
| 96 | + printf("0x%0*llX\n", (width >> 2), (unsigned long long)read_result); | ||
| 97 | } | ||
| 98 | -// printf("Value at address 0x%"OFF_FMT"X (%p): 0x%llX\n", | ||
| 99 | -// target, virt_addr, | ||
| 100 | -// (unsigned long long)read_result); | ||
| 101 | - /* Zero-padded output shows the width of access just done */ | ||
| 102 | - printf("0x%0*llX\n", (width >> 2), (unsigned long long)read_result); | ||
| 103 | } else { | ||
| 104 | + /* parse VALUE */ | ||
| 105 | +#ifdef __SIZEOF_INT128__ | ||
| 106 | + unsigned __int128 writeval = strtoumax(argv[3], NULL, 0); | ||
| 107 | +#else | ||
| 108 | + uint64_t writeval = bb_strtoull(argv[3], NULL, 0); | ||
| 109 | +#endif | ||
| 110 | switch (width) { | ||
| 111 | case 8: | ||
| 112 | *(volatile uint8_t*)virt_addr = writeval; | ||
| 113 | @@ -135,6 +149,12 @@ int devmem_main(int argc UNUSED_PARAM, char **argv) | ||
| 114 | *(volatile uint64_t*)virt_addr = writeval; | ||
| 115 | // read_result = *(volatile uint64_t*)virt_addr; | ||
| 116 | break; | ||
| 117 | +#ifdef __SIZEOF_INT128__ | ||
| 118 | + case 128: | ||
| 119 | + *(volatile unsigned __int128 *)virt_addr = writeval; | ||
| 120 | +// read_result = *(volatile uint64_t*)virt_addr; | ||
| 121 | + break; | ||
| 122 | +#endif | ||
| 123 | default: | ||
| 124 | bb_simple_error_msg_and_die("bad width"); | ||
| 125 | } | ||
| 126 | -- | ||
| 127 | 2.25.1 | ||
| 128 | |||
diff --git a/meta/recipes-core/busybox/busybox/CVE-2022-30065.patch b/meta/recipes-core/busybox/busybox/CVE-2022-30065.patch deleted file mode 100644 index 25ad653b25..0000000000 --- a/meta/recipes-core/busybox/busybox/CVE-2022-30065.patch +++ /dev/null | |||
| @@ -1,29 +0,0 @@ | |||
| 1 | Fix use-after-free in awk. | ||
| 2 | |||
| 3 | CVE: CVE-2022-30065 | ||
| 4 | Upstream-Status: Submitted [http://lists.busybox.net/pipermail/busybox/2022-June/089768.html] | ||
| 5 | Signed-off-by: Ross Burton <ross.burton@arm.com> | ||
| 6 | |||
| 7 | fixes https://bugs.busybox.net/show_bug.cgi?id=14781 | ||
| 8 | |||
| 9 | Signed-off-by: Natanael Copa <ncopa at alpinelinux.org> | ||
| 10 | --- | ||
| 11 | editors/awk.c | 3 +++ | ||
| 12 | 1 file changed, 3 insertions(+) | ||
| 13 | |||
| 14 | diff --git a/editors/awk.c b/editors/awk.c | ||
| 15 | index 079d0bde5..728ee8685 100644 | ||
| 16 | --- a/editors/awk.c | ||
| 17 | +++ b/editors/awk.c | ||
| 18 | @@ -3128,6 +3128,9 @@ static var *evaluate(node *op, var *res) | ||
| 19 | |||
| 20 | case XC( OC_MOVE ): | ||
| 21 | debug_printf_eval("MOVE\n"); | ||
| 22 | + /* make sure that we never return a temp var */ | ||
| 23 | + if (L.v == TMPVAR0) | ||
| 24 | + L.v = res; | ||
| 25 | /* if source is a temporary string, jusk relink it to dest */ | ||
| 26 | if (R.v == TMPVAR1 | ||
| 27 | && !(R.v->type & VF_NUMBER) | ||
| 28 | -- | ||
| 29 | 2.36.1 | ||
diff --git a/meta/recipes-core/busybox/busybox/defconfig b/meta/recipes-core/busybox/busybox/defconfig index 5e1e1f5638..3d36447c63 100644 --- a/meta/recipes-core/busybox/busybox/defconfig +++ b/meta/recipes-core/busybox/busybox/defconfig | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | # | 1 | # |
| 2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
| 3 | # Busybox version: 1.35.0 | 3 | # Busybox version: 1.36.0 |
| 4 | # Sun Dec 26 16:55:55 2021 | 4 | # Tue Jan 3 14:17:01 2023 |
| 5 | # | 5 | # |
| 6 | CONFIG_HAVE_DOT_CONFIG=y | 6 | CONFIG_HAVE_DOT_CONFIG=y |
| 7 | 7 | ||
| @@ -123,6 +123,9 @@ CONFIG_UNICODE_WIDE_WCHARS=y | |||
| 123 | # CONFIG_UNICODE_BIDI_SUPPORT is not set | 123 | # CONFIG_UNICODE_BIDI_SUPPORT is not set |
| 124 | # CONFIG_UNICODE_NEUTRAL_TABLE is not set | 124 | # CONFIG_UNICODE_NEUTRAL_TABLE is not set |
| 125 | # CONFIG_UNICODE_PRESERVE_BROKEN is not set | 125 | # CONFIG_UNICODE_PRESERVE_BROKEN is not set |
| 126 | # CONFIG_LOOP_CONFIGURE is not set | ||
| 127 | # CONFIG_NO_LOOP_CONFIGURE is not set | ||
| 128 | CONFIG_TRY_LOOP_CONFIGURE=y | ||
| 126 | 129 | ||
| 127 | # | 130 | # |
| 128 | # Applets | 131 | # Applets |
| @@ -338,6 +341,7 @@ CONFIG_FEATURE_TR_CLASSES=y | |||
| 338 | # CONFIG_FEATURE_TR_EQUIV is not set | 341 | # CONFIG_FEATURE_TR_EQUIV is not set |
| 339 | CONFIG_TRUE=y | 342 | CONFIG_TRUE=y |
| 340 | # CONFIG_TRUNCATE is not set | 343 | # CONFIG_TRUNCATE is not set |
| 344 | # CONFIG_TSORT is not set | ||
| 341 | CONFIG_TTY=y | 345 | CONFIG_TTY=y |
| 342 | CONFIG_UNAME=y | 346 | CONFIG_UNAME=y |
| 343 | CONFIG_UNAME_OSNAME="GNU/Linux" | 347 | CONFIG_UNAME_OSNAME="GNU/Linux" |
| @@ -831,10 +835,12 @@ CONFIG_MICROCOM=y | |||
| 831 | CONFIG_RFKILL=y | 835 | CONFIG_RFKILL=y |
| 832 | # CONFIG_RUNLEVEL is not set | 836 | # CONFIG_RUNLEVEL is not set |
| 833 | # CONFIG_RX is not set | 837 | # CONFIG_RX is not set |
| 838 | # CONFIG_SEEDRNG is not set | ||
| 834 | # CONFIG_SETFATTR is not set | 839 | # CONFIG_SETFATTR is not set |
| 835 | # CONFIG_SETSERIAL is not set | 840 | # CONFIG_SETSERIAL is not set |
| 836 | CONFIG_STRINGS=y | 841 | CONFIG_STRINGS=y |
| 837 | CONFIG_TIME=y | 842 | CONFIG_TIME=y |
| 843 | # CONFIG_TREE is not set | ||
| 838 | CONFIG_TS=y | 844 | CONFIG_TS=y |
| 839 | # CONFIG_TTYSIZE is not set | 845 | # CONFIG_TTYSIZE is not set |
| 840 | # CONFIG_UBIATTACH is not set | 846 | # CONFIG_UBIATTACH is not set |
diff --git a/meta/recipes-core/busybox/busybox/recognize_connmand.patch b/meta/recipes-core/busybox/busybox/recognize_connmand.patch index f42c74caad..4f28beb556 100644 --- a/meta/recipes-core/busybox/busybox/recognize_connmand.patch +++ b/meta/recipes-core/busybox/busybox/recognize_connmand.patch | |||
| @@ -4,14 +4,14 @@ Upstream-Status: Inappropriate [OE-Core] | |||
| 4 | 4 | ||
| 5 | Signed-off-by: Saul Wold <sgw@linux.intel.com> | 5 | Signed-off-by: Saul Wold <sgw@linux.intel.com> |
| 6 | 6 | ||
| 7 | Index: busybox-1.22.1/networking/ifupdown.c | 7 | Index: busybox-1.36.0/networking/ifupdown.c |
| 8 | =================================================================== | 8 | =================================================================== |
| 9 | --- busybox-1.22.1.orig/networking/ifupdown.c | 9 | --- busybox-1.36.0.orig/networking/ifupdown.c |
| 10 | +++ busybox-1.22.1/networking/ifupdown.c | 10 | +++ busybox-1.36.0/networking/ifupdown.c |
| 11 | @@ -521,6 +521,10 @@ struct dhcp_client_t { | 11 | @@ -628,6 +628,10 @@ struct dhcp_client_t { |
| 12 | }; | 12 | }; |
| 13 | 13 | ||
| 14 | static const struct dhcp_client_t ext_dhcp_clients[] = { | 14 | static const struct dhcp_client_t ext_dhcp_clients[] ALIGN_PTR = { |
| 15 | + { "connmand", | 15 | + { "connmand", |
| 16 | + "true", | 16 | + "true", |
| 17 | + "true", | 17 | + "true", |
diff --git a/meta/recipes-core/busybox/busybox/sha1sum.cfg b/meta/recipes-core/busybox/busybox/sha1sum.cfg index 20e72d9263..01137a2486 100644 --- a/meta/recipes-core/busybox/busybox/sha1sum.cfg +++ b/meta/recipes-core/busybox/busybox/sha1sum.cfg | |||
| @@ -1 +1,3 @@ | |||
| 1 | CONFIG_SHA1SUM=y | 1 | CONFIG_SHA1SUM=y |
| 2 | CONFIG_SHA1_SMALL=3 | ||
| 3 | CONFIG_SHA1_HWACCEL=y | ||
diff --git a/meta/recipes-core/busybox/busybox/sha256sum.cfg b/meta/recipes-core/busybox/busybox/sha256sum.cfg index ce652ae4c6..a5b0ab22d1 100644 --- a/meta/recipes-core/busybox/busybox/sha256sum.cfg +++ b/meta/recipes-core/busybox/busybox/sha256sum.cfg | |||
| @@ -1 +1,2 @@ | |||
| 1 | CONFIG_SHA256SUM=y | 1 | CONFIG_SHA256SUM=y |
| 2 | CONFIG_SHA256_HWACCEL=y | ||
diff --git a/meta/recipes-core/busybox/busybox_1.35.0.bb b/meta/recipes-core/busybox/busybox_1.36.0.bb index e9ca6fdb1a..e46d43e681 100644 --- a/meta/recipes-core/busybox/busybox_1.35.0.bb +++ b/meta/recipes-core/busybox/busybox_1.36.0.bb | |||
| @@ -49,9 +49,7 @@ SRC_URI = "https://busybox.net/downloads/busybox-${PV}.tar.bz2;name=tarball \ | |||
| 49 | file://0001-sysctl-ignore-EIO-of-stable_secret-below-proc-sys-ne.patch \ | 49 | file://0001-sysctl-ignore-EIO-of-stable_secret-below-proc-sys-ne.patch \ |
| 50 | file://0001-libbb-sockaddr2str-ensure-only-printable-characters-.patch \ | 50 | file://0001-libbb-sockaddr2str-ensure-only-printable-characters-.patch \ |
| 51 | file://0002-nslookup-sanitize-all-printed-strings-with-printable.patch \ | 51 | file://0002-nslookup-sanitize-all-printed-strings-with-printable.patch \ |
| 52 | file://CVE-2022-30065.patch \ | ||
| 53 | file://0001-devmem-add-128-bit-width.patch \ | ||
| 54 | " | 52 | " |
| 55 | SRC_URI:append:libc-musl = " file://musl.cfg " | 53 | SRC_URI:append:libc-musl = " file://musl.cfg " |
| 56 | 54 | ||
| 57 | SRC_URI[tarball.sha256sum] = "faeeb244c35a348a334f4a59e44626ee870fb07b6884d68c10ae8bc19f83a694" | 55 | SRC_URI[tarball.sha256sum] = "542750c8af7cb2630e201780b4f99f3dcceeb06f505b479ec68241c1e6af61a5" |
