diff options
author | A. Wilcox <awilcox@wilcox-tech.com> | 2019-02-26 17:26:55 +0000 |
---|---|---|
committer | A. Wilcox <awilcox@wilcox-tech.com> | 2019-02-26 17:26:55 +0000 |
commit | f5f17b24b3fa8017760ac3d09f22bfc86e52bf57 (patch) | |
tree | 615baf50f5556d00b750046b0c9cdbf78b2bac2a /legacy | |
parent | ba5fe57ac3da43128560a805407bc66718ece336 (diff) | |
parent | 4618f5695b7bd00c07d656e965db11b31f0d8b36 (diff) | |
download | packages-f5f17b24b3fa8017760ac3d09f22bfc86e52bf57.tar.gz packages-f5f17b24b3fa8017760ac3d09f22bfc86e52bf57.tar.bz2 packages-f5f17b24b3fa8017760ac3d09f22bfc86e52bf57.tar.xz packages-f5f17b24b3fa8017760ac3d09f22bfc86e52bf57.zip |
Merge branch 'busyborks' into 'master'
Deprecate busybox package due to insane maintanership burden nobody is willing to take up.
See merge request !183
Diffstat (limited to 'legacy')
47 files changed, 6406 insertions, 0 deletions
diff --git a/legacy/busybox/0001-ash-add-support-for-command_not_found_handle-hook-fu.patch b/legacy/busybox/0001-ash-add-support-for-command_not_found_handle-hook-fu.patch new file mode 100644 index 000000000..929370b9d --- /dev/null +++ b/legacy/busybox/0001-ash-add-support-for-command_not_found_handle-hook-fu.patch @@ -0,0 +1,63 @@ +From 185ba65457e991ebd0f6e64266380df5e11cc489 Mon Sep 17 00:00:00 2001 +From: William Pitcock <nenolod@dereferenced.org> +Date: Thu, 19 Oct 2017 17:24:40 +0000 +Subject: [PATCH 01/16] ash: add support for command_not_found_handle hook + function, like bash + +This implements support for the command_not_found_handle hook function, which is +useful for allowing package managers to suggest packages which could provide the +command. + +Unlike bash, however, we ignore exit codes from the hook function and always return +the correct POSIX error code (EX_NOTFOUND). + +Signed-off-by: William Pitcock <nenolod@dereferenced.org> +--- + shell/ash.c | 24 ++++++++++++++++++++++-- + 1 file changed, 22 insertions(+), 2 deletions(-) + +diff --git a/shell/ash.c b/shell/ash.c +index b73a79975..7ceb91920 100644 +--- a/shell/ash.c ++++ b/shell/ash.c +@@ -132,6 +132,15 @@ + //config: you to run the specified command or builtin, + //config: even when there is a function with the same name. + //config: ++//config:config ASH_COMMAND_NOT_FOUND_HOOK ++//config: bool "command_not_found_handle hook support" ++//config: default y ++//config: depends on ASH || SH_IS_ASH || BASH_IS_ASH ++//config: help ++//config: Enable support for the 'command_not_found_handle' hook function, ++//config: from GNU bash, which allows for alternative command not found ++//config: handling. ++//config: + //config:endif # ash options + + //applet:IF_ASH(APPLET(ash, BB_DIR_BIN, BB_SUID_DROP)) +@@ -13166,8 +13175,19 @@ find_command(char *name, struct cmdentry *entry, int act, const char *path) + /* We failed. If there was an entry for this command, delete it */ + if (cmdp && updatetbl) + delete_cmd_entry(); +- if (act & DO_ERR) +- ash_msg("%s: %s", name, errmsg(e, "not found")); ++ if (act & DO_ERR) { ++#ifdef CONFIG_ASH_COMMAND_NOT_FOUND_HOOK ++#define HOOKFN_NAME "command_not_found_handle" ++ char hookfn_name[] = HOOKFN_NAME; ++ struct tblentry *hookp = cmdlookup(hookfn_name, 0); ++ if (hookp != NULL && hookp->cmdtype == CMDFUNCTION) { ++ evalfun(hookp->param.func, 2, (char *[]){ hookfn_name, name }, 0); ++ entry->cmdtype = CMDUNKNOWN; ++ return; ++ } else ++#endif ++ ash_msg("%s: %s", name, errmsg(e, "not found")); ++ } + entry->cmdtype = CMDUNKNOWN; + return; + +-- +2.16.2 + diff --git a/legacy/busybox/0001-ash-exec-busybox.static.patch b/legacy/busybox/0001-ash-exec-busybox.static.patch new file mode 100644 index 000000000..fdf134960 --- /dev/null +++ b/legacy/busybox/0001-ash-exec-busybox.static.patch @@ -0,0 +1,25 @@ +From 134582e8dd1c85cbcf1fc047956a57fcd642e46a Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Thu, 4 Aug 2016 11:03:07 +0200 +Subject: [PATCH 01/11] ash: exec busybox.static + +--- + shell/ash.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/shell/ash.c b/shell/ash.c +index b7635a823..e613ee6bb 100644 +--- a/shell/ash.c ++++ b/shell/ash.c +@@ -7721,6 +7721,8 @@ tryexec(IF_FEATURE_SH_STANDALONE(int applet_no,) char *cmd, char **argv, char ** + } + /* re-exec ourselves with the new arguments */ + execve(bb_busybox_exec_path, argv, envp); ++ execve("/bin/busybox.static",argv,envp); ++ execve("/bin/busybox",argv,envp); + /* If they called chroot or otherwise made the binary no longer + * executable, fall through */ + } +-- +2.13.2 + diff --git a/legacy/busybox/0001-cat-fix-cat-e-and-cat-v-erroneously-numbering-1st-li.patch b/legacy/busybox/0001-cat-fix-cat-e-and-cat-v-erroneously-numbering-1st-li.patch new file mode 100644 index 000000000..4680b920e --- /dev/null +++ b/legacy/busybox/0001-cat-fix-cat-e-and-cat-v-erroneously-numbering-1st-li.patch @@ -0,0 +1,63 @@ +From d80eecb86812c1fbda652f9b995060c26ba0b155 Mon Sep 17 00:00:00 2001 +From: Denys Vlasenko <vda.linux@googlemail.com> +Date: Sun, 29 Apr 2018 14:05:43 +0200 +Subject: [PATCH] cat: fix cat -e and cat -v erroneously numbering 1st line + +function old new delta +cat_main 418 421 +3 + +Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com> +--- + coreutils/cat.c | 6 +++--- + testsuite/cat.tests | 21 +++++++++++++++++++++ + 2 files changed, 24 insertions(+), 3 deletions(-) + create mode 100755 testsuite/cat.tests + +diff --git a/coreutils/cat.c b/coreutils/cat.c +index 5f02233ca..fb735f994 100644 +--- a/coreutils/cat.c ++++ b/coreutils/cat.c +@@ -112,10 +112,10 @@ static int catv(unsigned opts, char **argv) + int retval = EXIT_SUCCESS; + int fd; + #if ENABLE_FEATURE_CATN +- unsigned lineno = 0; +- unsigned eol_char = (opts & (CAT_OPT_n|CAT_OPT_b)) ? '\n' : 0x100; ++ bool eol_seen = (opts & (CAT_OPT_n|CAT_OPT_b)); ++ unsigned eol_char = (eol_seen ? '\n' : 0x100); + unsigned skip_num_on = (opts & CAT_OPT_b) ? '\n' : 0x100; +- bool eol_seen = 1; ++ unsigned lineno = 0; + #endif + + BUILD_BUG_ON(CAT_OPT_e != VISIBLE_ENDLINE); +diff --git a/testsuite/cat.tests b/testsuite/cat.tests +new file mode 100755 +index 000000000..404ebedeb +--- /dev/null ++++ b/testsuite/cat.tests +@@ -0,0 +1,21 @@ ++#!/bin/sh ++ ++# Copyright 2018 by Denys Vlasenko <vda.linux@googlemail.com> ++# Licensed under GPLv2, see file LICENSE in this source tree. ++ ++. ./testing.sh ++ ++# testing "description" "command" "result" "infile" "stdin" ++testing 'cat -e' \ ++ 'cat -e' \ ++ 'foo$\n' \ ++ '' \ ++ 'foo\n' ++ ++testing 'cat -v' \ ++ 'cat -v' \ ++ 'foo\n' \ ++ '' \ ++ 'foo\n' ++ ++exit $FAILCOUNT +-- +2.17.0 + diff --git a/legacy/busybox/0001-wget-emit-a-message-that-certificate-verification-is.patch b/legacy/busybox/0001-wget-emit-a-message-that-certificate-verification-is.patch new file mode 100644 index 000000000..3780b039e --- /dev/null +++ b/legacy/busybox/0001-wget-emit-a-message-that-certificate-verification-is.patch @@ -0,0 +1,67 @@ +From 948090c675f8b60b74c7357fcafb1cc8c179e0a6 Mon Sep 17 00:00:00 2001 +From: Denys Vlasenko <vda.linux@googlemail.com> +Date: Mon, 28 May 2018 14:36:26 +0200 +Subject: [PATCH] wget: emit a message that certificate verification is not + implemented + +function old new delta +spawn_ssl_client 185 209 +24 + +Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com> +--- + networking/wget.c | 9 +++++++-- + 1 file changed, 7 insertions(+), 2 deletions(-) + +diff --git a/networking/wget.c b/networking/wget.c +index d1d85230c..cd92b3a28 100644 +--- a/networking/wget.c ++++ b/networking/wget.c +@@ -136,6 +136,7 @@ + //usage: "Retrieve files via HTTP or FTP\n" + //usage: IF_FEATURE_WGET_LONG_OPTIONS( + //usage: "\n --spider Only check URL existence: $? is 0 if exists" ++///////: "\n --no-check-certificate Don't validate the server's certificate" + //usage: ) + //usage: "\n -c Continue retrieval of aborted transfer" + //usage: "\n -q Quiet" +@@ -267,6 +268,7 @@ enum { + WGET_OPT_HEADER = (1 << 10) * ENABLE_FEATURE_WGET_LONG_OPTIONS, + WGET_OPT_POST_DATA = (1 << 11) * ENABLE_FEATURE_WGET_LONG_OPTIONS, + WGET_OPT_SPIDER = (1 << 12) * ENABLE_FEATURE_WGET_LONG_OPTIONS, ++ WGET_OPT_NO_CHECK_CERT = (1 << 13) * ENABLE_FEATURE_WGET_LONG_OPTIONS, + }; + + enum { +@@ -765,6 +767,9 @@ static void spawn_ssl_client(const char *host, int network_fd) + int pid; + char *servername, *p; + ++ if (!(option_mask32 & WGET_OPT_NO_CHECK_CERT)) ++ bb_error_msg("note: TLS certificate validation not implemented"); ++ + servername = xstrdup(host); + p = strrchr(servername, ':'); + if (p) *p = '\0'; +@@ -1353,10 +1358,9 @@ IF_DESKTOP( "tries\0" Required_argument "t") + "header\0" Required_argument "\xff" + "post-data\0" Required_argument "\xfe" + "spider\0" No_argument "\xfd" ++ "no-check-certificate\0" No_argument "\xfc" + /* Ignored (we always use PASV): */ + IF_DESKTOP( "passive-ftp\0" No_argument "\xf0") +- /* Ignored (we don't do ssl) */ +-IF_DESKTOP( "no-check-certificate\0" No_argument "\xf0") + /* Ignored (we don't support caching) */ + IF_DESKTOP( "no-cache\0" No_argument "\xf0") + IF_DESKTOP( "no-verbose\0" No_argument "\xf0") +@@ -1416,6 +1420,7 @@ IF_DESKTOP( "no-parent\0" No_argument "\xf0") + if (option_mask32 & WGET_OPT_HEADER) bb_error_msg("--header"); + if (option_mask32 & WGET_OPT_POST_DATA) bb_error_msg("--post-data"); + if (option_mask32 & WGET_OPT_SPIDER) bb_error_msg("--spider"); ++ if (option_mask32 & WGET_OPT_NO_CHECK_CERT) bb_error_msg("--no-check-certificate"); + exit(0); + #endif + argv += optind; +-- +2.17.0 + diff --git a/legacy/busybox/0002-app-location-for-cpio-vi-and-lspci.patch b/legacy/busybox/0002-app-location-for-cpio-vi-and-lspci.patch new file mode 100644 index 000000000..8c8e4ee7a --- /dev/null +++ b/legacy/busybox/0002-app-location-for-cpio-vi-and-lspci.patch @@ -0,0 +1,54 @@ +From 8937e2dfb3dbfa23597853e9605f930b3607fa63 Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Tue, 27 Dec 2016 20:46:59 +0100 +Subject: [PATCH 02/11] app location for cpio, vi and lspci + +Adjust location to where alpine linux installs them +--- + archival/cpio.c | 2 +- + editors/vi.c | 2 +- + util-linux/lspci.c | 2 +- + 3 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/archival/cpio.c b/archival/cpio.c +index 683f0bb1f..45362b6bc 100644 +--- a/archival/cpio.c ++++ b/archival/cpio.c +@@ -43,7 +43,7 @@ + //config: help + //config: Passthrough mode. Rarely used. + +-//applet:IF_CPIO(APPLET(cpio, BB_DIR_BIN, BB_SUID_DROP)) ++//applet:IF_CPIO(APPLET(cpio, BB_DIR_USR_BIN, BB_SUID_DROP)) + //kbuild:lib-$(CONFIG_CPIO) += cpio.o + + //usage:#define cpio_trivial_usage +diff --git a/editors/vi.c b/editors/vi.c +index 76d1f261b..73d0a67a9 100644 +--- a/editors/vi.c ++++ b/editors/vi.c +@@ -163,7 +163,7 @@ + //config: Unless you want more (or less) frequent "undo points" while typing, + //config: you should probably leave this unchanged. + +-//applet:IF_VI(APPLET(vi, BB_DIR_BIN, BB_SUID_DROP)) ++//applet:IF_VI(APPLET(vi, BB_DIR_USR_BIN, BB_SUID_DROP)) + + //kbuild:lib-$(CONFIG_VI) += vi.o + +diff --git a/util-linux/lspci.c b/util-linux/lspci.c +index 8b38a2366..f918f0972 100644 +--- a/util-linux/lspci.c ++++ b/util-linux/lspci.c +@@ -16,7 +16,7 @@ + //config: + //config: This version uses sysfs (/sys/bus/pci/devices) only. + +-//applet:IF_LSPCI(APPLET(lspci, BB_DIR_USR_BIN, BB_SUID_DROP)) ++//applet:IF_LSPCI(APPLET(lspci, BB_DIR_USR_SBIN, BB_SUID_DROP)) + + //kbuild:lib-$(CONFIG_LSPCI) += lspci.o + +-- +2.13.2 + diff --git a/legacy/busybox/0002-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch b/legacy/busybox/0002-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch new file mode 100644 index 000000000..72df8ecf9 --- /dev/null +++ b/legacy/busybox/0002-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch @@ -0,0 +1,59 @@ +From bce882404ab41d32d5d9def274e49264717135b2 Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Tue, 28 Nov 2017 13:23:17 +0100 +Subject: [PATCH 02/16] fsck: resolve LABEL=.../UUID=... spec to device + +--- + e2fsprogs/fsck.c | 10 +++++----- + 1 file changed, 5 insertions(+), 5 deletions(-) + +diff --git a/e2fsprogs/fsck.c b/e2fsprogs/fsck.c +index 1c285bb92..5af38c0aa 100644 +--- a/e2fsprogs/fsck.c ++++ b/e2fsprogs/fsck.c +@@ -60,6 +60,7 @@ + //usage: "\n -t TYPE List of filesystem types to check" + + #include "libbb.h" ++#include "volume_id.h" + #include "common_bufsiz.h" + + /* "progress indicator" code is somewhat buggy and ext[23] specific. +@@ -523,12 +524,13 @@ static int wait_many(int flags) + * Execute a particular fsck program, and link it into the list of + * child processes we are waiting for. + */ +-static void execute(const char *type, const char *device, ++static void execute(const char *type, const char *spec, + const char *mntpt /*, int interactive */) + { + int i; + struct fsck_instance *inst; + pid_t pid; ++ char *device = (char *)spec; + + G.args[0] = xasprintf("fsck.%s", type); + +@@ -543,7 +545,8 @@ static void execute(const char *type, const char *device, + } + #endif + +- G.args[G.num_args - 2] = (char*)device; ++ resolve_mount_spec(&device); ++ G.args[G.num_args - 2] = device; + /* G.args[G.num_args - 1] = NULL; - already is */ + + if (G.verbose || G.noexecute) { +@@ -972,9 +975,6 @@ int fsck_main(int argc UNUSED_PARAM, char **argv) + + /* "/dev/blk" or "/path" or "UUID=xxx" or "LABEL=xxx" */ + if ((arg[0] == '/' && !opts_for_fsck) || strchr(arg, '=')) { +-// FIXME: must check that arg is a blkdev, or resolve +-// "/path", "UUID=xxx" or "LABEL=xxx" into block device name +-// ("UUID=xxx"/"LABEL=xxx" can probably shifted to fsck.auto duties) + devices = xrealloc_vector(devices, 2, num_devices); + devices[num_devices++] = arg; + continue; +-- +2.16.2 + diff --git a/legacy/busybox/0003-ash-exec-busybox.static.patch b/legacy/busybox/0003-ash-exec-busybox.static.patch new file mode 100644 index 000000000..94239a2eb --- /dev/null +++ b/legacy/busybox/0003-ash-exec-busybox.static.patch @@ -0,0 +1,25 @@ +From 36b6cc36d1f259e4ac76a1c2de743113845ff4cd Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Thu, 4 Aug 2016 11:03:07 +0200 +Subject: [PATCH 03/16] ash: exec busybox.static + +--- + shell/ash.c | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/shell/ash.c b/shell/ash.c +index 7ceb91920..d04096a9b 100644 +--- a/shell/ash.c ++++ b/shell/ash.c +@@ -7845,6 +7845,8 @@ tryexec(IF_FEATURE_SH_STANDALONE(int applet_no,) const char *cmd, char **argv, c + } + /* re-exec ourselves with the new arguments */ + execve(bb_busybox_exec_path, argv, envp); ++ execve("/bin/busybox.static",argv,envp); ++ execve("/bin/busybox",argv,envp); + /* If they called chroot or otherwise made the binary no longer + * executable, fall through */ + } +-- +2.16.2 + diff --git a/legacy/busybox/0003-udhcpc-set-default-discover-retries-to-5.patch b/legacy/busybox/0003-udhcpc-set-default-discover-retries-to-5.patch new file mode 100644 index 000000000..5671ee1b0 --- /dev/null +++ b/legacy/busybox/0003-udhcpc-set-default-discover-retries-to-5.patch @@ -0,0 +1,35 @@ +From 18415adc1cd9993a95d100dd773daf69b8ec819e Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Thu, 4 Aug 2016 11:08:35 +0200 +Subject: [PATCH 03/11] udhcpc: set default discover retries to 5 + +Some slower nics needs more attempts to get a lease +--- + networking/udhcp/dhcpc.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c +index 1a66c610e..43aac1b85 100644 +--- a/networking/udhcp/dhcpc.c ++++ b/networking/udhcp/dhcpc.c +@@ -1191,7 +1191,7 @@ static void client_background(void) + //usage: "\n -s,--script PROG Run PROG at DHCP events (default "CONFIG_UDHCPC_DEFAULT_SCRIPT")" + //usage: "\n -p,--pidfile FILE Create pidfile" + //usage: "\n -B,--broadcast Request broadcast replies" +-//usage: "\n -t,--retries N Send up to N discover packets (default 3)" ++//usage: "\n -t,--retries N Send up to N discover packets (default 5)" + //usage: "\n -T,--timeout SEC Pause between packets (default 3)" + //usage: "\n -A,--tryagain SEC Wait if lease is not obtained (default 20)" + //usage: "\n -n,--now Exit if lease is not obtained" +@@ -1274,7 +1274,7 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv) + llist_t *list_x = NULL; + int tryagain_timeout = 20; + int discover_timeout = 3; +- int discover_retries = 3; ++ int discover_retries = 5; + uint32_t server_addr = server_addr; /* for compiler */ + uint32_t requested_ip = 0; + uint32_t xid = xid; /* for compiler */ +-- +2.13.2 + diff --git a/legacy/busybox/0004-app-location-for-cpio-vi-and-lspci.patch b/legacy/busybox/0004-app-location-for-cpio-vi-and-lspci.patch new file mode 100644 index 000000000..7f105cb67 --- /dev/null +++ b/legacy/busybox/0004-app-location-for-cpio-vi-and-lspci.patch @@ -0,0 +1,54 @@ +From 9bbc93f12f7cff8fb51a0bf89907d9875f5c14e6 Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Tue, 27 Dec 2016 20:46:59 +0100 +Subject: [PATCH 04/16] app location for cpio, vi and lspci + +Adjust location to where alpine linux installs them +--- + archival/cpio.c | 2 +- + editors/vi.c | 2 +- + util-linux/lspci.c | 2 +- + 3 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/archival/cpio.c b/archival/cpio.c +index 1d6cbd1e2..0c14f79e7 100644 +--- a/archival/cpio.c ++++ b/archival/cpio.c +@@ -39,7 +39,7 @@ + //config: help + //config: Passthrough mode. Rarely used. + +-//applet:IF_CPIO(APPLET(cpio, BB_DIR_BIN, BB_SUID_DROP)) ++//applet:IF_CPIO(APPLET(cpio, BB_DIR_USR_BIN, BB_SUID_DROP)) + + //kbuild:lib-$(CONFIG_CPIO) += cpio.o + +diff --git a/editors/vi.c b/editors/vi.c +index cdfb27cc5..20077727e 100644 +--- a/editors/vi.c ++++ b/editors/vi.c +@@ -161,7 +161,7 @@ + //config: Unless you want more (or less) frequent "undo points" while typing, + //config: you should probably leave this unchanged. + +-//applet:IF_VI(APPLET(vi, BB_DIR_BIN, BB_SUID_DROP)) ++//applet:IF_VI(APPLET(vi, BB_DIR_USR_BIN, BB_SUID_DROP)) + + //kbuild:lib-$(CONFIG_VI) += vi.o + +diff --git a/util-linux/lspci.c b/util-linux/lspci.c +index 0000fbfda..34189d2b5 100644 +--- a/util-linux/lspci.c ++++ b/util-linux/lspci.c +@@ -16,7 +16,7 @@ + //config: + //config: This version uses sysfs (/sys/bus/pci/devices) only. + +-//applet:IF_LSPCI(APPLET_NOEXEC(lspci, lspci, BB_DIR_USR_BIN, BB_SUID_DROP, lspci)) ++//applet:IF_LSPCI(APPLET_NOEXEC(lspci, lspci, BB_DIR_USR_SBIN, BB_SUID_DROP, lspci)) + + //kbuild:lib-$(CONFIG_LSPCI) += lspci.o + +-- +2.16.2 + diff --git a/legacy/busybox/0004-ping-make-ping-work-without-root-privileges.patch b/legacy/busybox/0004-ping-make-ping-work-without-root-privileges.patch new file mode 100644 index 000000000..77fa5ed76 --- /dev/null +++ b/legacy/busybox/0004-ping-make-ping-work-without-root-privileges.patch @@ -0,0 +1,197 @@ +From bef770d1ee4179e380dff24305d9b6d899147add Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Tue, 29 Mar 2016 18:59:22 +0200 +Subject: [PATCH 04/11] ping: make ping work without root privileges + +--- + networking/ping.c | 103 +++++++++++++++++++++++++++++++++++++++++++++--------- + 1 file changed, 87 insertions(+), 16 deletions(-) + +diff --git a/networking/ping.c b/networking/ping.c +index 94fb007f5..26e40e1fc 100644 +--- a/networking/ping.c ++++ b/networking/ping.c +@@ -155,6 +155,7 @@ enum { + pingsock = 0, + }; + ++static int using_dgram; + static void + #if ENABLE_PING6 + create_icmp_socket(len_and_sockaddr *lsa) +@@ -171,9 +172,23 @@ create_icmp_socket(void) + #endif + sock = socket(AF_INET, SOCK_RAW, 1); /* 1 == ICMP */ + if (sock < 0) { +- if (errno == EPERM) +- bb_error_msg_and_die(bb_msg_perm_denied_are_you_root); +- bb_perror_msg_and_die(bb_msg_can_not_create_raw_socket); ++ if (errno != EPERM) ++ bb_perror_msg_and_die(bb_msg_can_not_create_raw_socket); ++#if defined(__linux__) || defined(__APPLE__) ++ /* We don't have root privileges. Try SOCK_DGRAM instead. ++ * Linux needs net.ipv4.ping_group_range for this to work. ++ * MacOSX allows ICMP_ECHO, ICMP_TSTAMP or ICMP_MASKREQ ++ */ ++#if ENABLE_PING6 ++ if (lsa->u.sa.sa_family == AF_INET6) ++ sock = socket(AF_INET6, SOCK_DGRAM, IPPROTO_ICMPV6); ++ else ++#endif ++ sock = socket(AF_INET, SOCK_DGRAM, 1); /* 1 == ICMP */ ++ if (sock < 0) ++#endif ++ bb_error_msg_and_die(bb_msg_perm_denied_are_you_root); ++ using_dgram = 1; + } + + xmove_fd(sock, pingsock); +@@ -226,10 +241,12 @@ static void ping4(len_and_sockaddr *lsa) + bb_perror_msg("recvfrom"); + continue; + } +- if (c >= 76) { /* ip + icmp */ +- struct iphdr *iphdr = (struct iphdr *) G.packet; ++ if (c >= 76 || using_dgram && (c == 64)) { /* ip + icmp */ ++ if(!using_dgram) { ++ struct iphdr *iphdr = (struct iphdr *) G.packet; + +- pkt = (struct icmp *) (G.packet + (iphdr->ihl << 2)); /* skip ip hdr */ ++ pkt = (struct icmp *) (G.packet + (iphdr->ihl << 2)); /* skip ip hdr */ ++ } else pkt = (struct icmp *) G.packet; + if (pkt->icmp_id != G.myid) + continue; /* not our ping */ + if (pkt->icmp_type == ICMP_ECHOREPLY) +@@ -627,19 +644,21 @@ static void unpack_tail(int sz, uint32_t *tp, + } + static void unpack4(char *buf, int sz, struct sockaddr_in *from) + { +- struct icmp *icmppkt; + struct iphdr *iphdr; ++ struct icmp *icmppkt; + int hlen; + + /* discard if too short */ + if (sz < (datalen + ICMP_MINLEN)) + return; ++ if(!using_dgram) { ++ /* check IP header */ ++ iphdr = (struct iphdr *) buf; ++ hlen = iphdr->ihl << 2; ++ sz -= hlen; ++ icmppkt = (struct icmp *) (buf + hlen); ++ } else icmppkt = (struct icmp *) buf; + +- /* check IP header */ +- iphdr = (struct iphdr *) buf; +- hlen = iphdr->ihl << 2; +- sz -= hlen; +- icmppkt = (struct icmp *) (buf + hlen); + if (icmppkt->icmp_id != myid) + return; /* not our ping */ + +@@ -651,7 +670,7 @@ static void unpack4(char *buf, int sz, struct sockaddr_in *from) + tp = (uint32_t *) icmppkt->icmp_data; + unpack_tail(sz, tp, + inet_ntoa(*(struct in_addr *) &from->sin_addr.s_addr), +- recv_seq, iphdr->ttl); ++ recv_seq, using_dgram ? 42 : iphdr->ttl); + } else if (icmppkt->icmp_type != ICMP_ECHO) { + bb_error_msg("warning: got ICMP %d (%s)", + icmppkt->icmp_type, +@@ -695,11 +714,31 @@ static void ping4(len_and_sockaddr *lsa) + int sockopt; + + pingaddr.sin = lsa->u.sin; +- if (source_lsa) { ++ if (source_lsa && !using_dgram) { + if (setsockopt(pingsock, IPPROTO_IP, IP_MULTICAST_IF, + &source_lsa->u.sa, source_lsa->len)) + bb_error_msg_and_die("can't set multicast source interface"); + xbind(pingsock, &source_lsa->u.sa, source_lsa->len); ++ } else if(using_dgram) { ++ struct sockaddr_in sa; ++ socklen_t sl; ++ ++ sa.sin_family = AF_INET; ++ sa.sin_port = 0; ++ sa.sin_addr.s_addr = source_lsa ? ++ source_lsa->u.sin.sin_addr.s_addr : 0; ++ sl = sizeof(sa); ++ ++ if (bind(pingsock, (struct sockaddr *) &sa, sl) == -1) { ++ perror("bind"); ++ exit(2); ++ } ++ ++ if (getsockname(pingsock, (struct sockaddr *) &sa, &sl) == -1) { ++ perror("getsockname"); ++ exit(2); ++ } ++ myid = sa.sin_port; + } + + /* enable broadcast pings */ +@@ -716,6 +755,15 @@ static void ping4(len_and_sockaddr *lsa) + setsockopt_int(pingsock, IPPROTO_IP, IP_MULTICAST_TTL, opt_ttl); + } + ++ if(using_dgram) { ++ int hold = 65536; ++ if (setsockopt(pingsock, SOL_IP, IP_RECVTTL, (char *)&hold, sizeof(hold))) ++ perror("WARNING: setsockopt(IP_RECVTTL)"); ++ if (setsockopt(pingsock, SOL_IP, IP_RETOPTS, (char *)&hold, sizeof(hold))) ++ perror("WARNING: setsockopt(IP_RETOPTS)"); ++ ++ } ++ + signal(SIGINT, print_stats_and_exit); + + /* start the ping's going ... */ +@@ -749,10 +797,33 @@ static void ping6(len_and_sockaddr *lsa) + char control_buf[CMSG_SPACE(36)]; + + pingaddr.sin6 = lsa->u.sin6; +- if (source_lsa) ++ if (source_lsa && !using_dgram) + xbind(pingsock, &source_lsa->u.sa, source_lsa->len); ++ else if(using_dgram) { ++ struct sockaddr_in6 sa = {0}; ++ socklen_t sl; ++ ++ sa.sin6_family = AF_INET6; ++ sa.sin6_port = 0; ++ if(source_lsa) { ++ memcpy(&sa.sin6_addr, &source_lsa->u.sin6.sin6_addr, sizeof(struct in6_addr)); ++ } ++ sl = sizeof(sa); ++ ++ if (bind(pingsock, (struct sockaddr *) &sa, sl) == -1) { ++ perror("bind"); ++ exit(2); ++ } ++ ++ if (getsockname(pingsock, (struct sockaddr *) &sa, &sl) == -1) { ++ perror("getsockname"); ++ exit(2); ++ } ++ myid = sa.sin6_port; ++ } + + #ifdef ICMP6_FILTER ++ if(!using_dgram) + { + struct icmp6_filter filt; + if (!(option_mask32 & OPT_VERBOSE)) { +@@ -880,7 +951,7 @@ static int common_ping_main(int opt, char **argv) + if (opt & OPT_p) + G.pattern = xstrtou_range(str_p, 16, 0, 255); + +- myid = (uint16_t) getpid(); ++ if (!using_dgram) myid = (uint16_t) getpid(); + hostname = argv[optind]; + #if ENABLE_PING6 + { +-- +2.13.2 + diff --git a/legacy/busybox/0005-fbsplash-support-console-switching.patch b/legacy/busybox/0005-fbsplash-support-console-switching.patch new file mode 100644 index 000000000..792c2d6c8 --- /dev/null +++ b/legacy/busybox/0005-fbsplash-support-console-switching.patch @@ -0,0 +1,187 @@ +From a8f7d33f47cc28732cd04573ae1fb6a1ca6e9617 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi> +Date: Mon, 24 Sep 2012 07:58:29 +0300 +Subject: [PATCH 05/11] fbsplash: support console switching +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Signed-off-by: Timo Teräs <timo.teras@iki.fi> +--- + miscutils/fbsplash.c | 83 +++++++++++++++++++++++++++++++++++++++++++++++----- + 1 file changed, 76 insertions(+), 7 deletions(-) + +diff --git a/miscutils/fbsplash.c b/miscutils/fbsplash.c +index fc6c9b953..ec5947314 100644 +--- a/miscutils/fbsplash.c ++++ b/miscutils/fbsplash.c +@@ -47,7 +47,7 @@ + //kbuild:lib-$(CONFIG_FBSPLASH) += fbsplash.o + + //usage:#define fbsplash_trivial_usage +-//usage: "-s IMGFILE [-c] [-d DEV] [-i INIFILE] [-f CMD]" ++//usage: "-s IMGFILE [-c] [-d DEV] [-i INIFILE] [-f CMD] [-T tty]" + //usage:#define fbsplash_full_usage "\n\n" + //usage: " -s Image" + //usage: "\n -c Hide cursor" +@@ -57,11 +57,17 @@ + //usage: "\n BAR_R,BAR_G,BAR_B" + //usage: "\n -f Control pipe (else exit after drawing image)" + //usage: "\n commands: 'NN' (% for progress bar) or 'exit'" ++//usage: "\n -T Switch to TTY to hide all console messages" + + #include "libbb.h" + #include "common_bufsiz.h" + #include <linux/fb.h> + ++#include <sys/vt.h> ++#include <sys/ioctl.h> ++#include <linux/tiocl.h> ++#include <linux/kd.h> ++ + /* If you want logging messages on /tmp/fbsplash.log... */ + #define DEBUG 0 + +@@ -73,6 +79,8 @@ struct globals { + unsigned char *addr; // pointer to framebuffer memory + unsigned ns[7]; // n-parameters + const char *image_filename; ++ int silent_tty, fd_tty_s; ++ bool do_not_draw; + struct fb_var_screeninfo scr_var; + struct fb_fix_screeninfo scr_fix; + unsigned bytes_per_pixel; +@@ -483,6 +491,11 @@ static void init(const char *cfg_filename) + config_close(parser); + } + ++static void sighandler(int sig) ++{ ++ ioctl(G.fd_tty_s, VT_RELDISP, sig == SIGUSR1 ? 1 : 2); ++ G.do_not_draw = (sig != SIGUSR2); ++} + + int fbsplash_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; + int fbsplash_main(int argc UNUSED_PARAM, char **argv) +@@ -492,6 +505,9 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + char *num_buf; + unsigned num; + bool bCursorOff; ++ int fd_tty0, active_vt; ++ struct vt_stat vtstat; ++ struct vt_mode vt; + + INIT_G(); + +@@ -499,8 +515,10 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + fb_device = "/dev/fb0"; + cfg_filename = NULL; + fifo_filename = NULL; +- bCursorOff = 1 & getopt32(argv, "cs:d:i:f:", +- &G.image_filename, &fb_device, &cfg_filename, &fifo_filename); ++ opt_complementary = "T+"; // numeric params ++ bCursorOff = 1 & getopt32(argv, "cs:d:i:f:T:", ++ &G.image_filename, &fb_device, &cfg_filename, &fifo_filename, ++ &G.silent_tty); + + // parse configuration file + if (cfg_filename) +@@ -510,11 +528,43 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + if (!G.image_filename) + bb_show_usage(); + ++ fd_tty0 = get_console_fd_or_die(); ++ if (G.silent_tty) { ++ char buf[16]; ++ ++ /* Initialize TTY */ ++ bb_signals((1LL << SIGUSR1) | (1LL << SIGUSR2), sighandler); ++ snprintf(buf, sizeof(buf), "/dev/tty%d", G.silent_tty); ++ G.fd_tty_s = xopen(buf, O_RDWR | O_NOCTTY); ++ ++ /* Activate TTY */ ++ xioctl(fd_tty0, VT_GETSTATE, &vtstat); ++ active_vt = vtstat.v_active; ++ console_make_active(fd_tty0, G.silent_tty); ++ ++ /* Get notifications on console changes */ ++ vt.mode = VT_PROCESS; ++ vt.waitv = 0; ++ vt.relsig = SIGUSR1; ++ vt.acqsig = SIGUSR2; ++ ioctl(G.fd_tty_s, VT_SETMODE, &vt); ++ ++ /* Redirect all kernel messages to tty1 so that they don't get ++ * printed over our silent splash image. And clear it. */ ++ buf[0] = TIOCL_SETKMSGREDIRECT; ++ buf[1] = 1; ++ ioctl(G.fd_tty_s, TIOCLINUX, buf); ++ full_write(G.fd_tty_s, "\e[H\e[2J" "\e[?17;0c", 7+8); ++ ioctl(G.fd_tty_s, KDSETMODE, KD_GRAPHICS); ++ } else { ++ G.fd_tty_s = STDOUT_FILENO; ++ } ++ + fb_open(fb_device); + + if (fifo_filename && bCursorOff) { + // hide cursor (BEFORE any fb ops) +- full_write(STDOUT_FILENO, "\033[?25l", 6); ++ full_write(G.fd_tty_s, "\033[?25l", 6); + } + + fb_drawimage(); +@@ -522,6 +572,7 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + if (!fifo_filename) + return EXIT_SUCCESS; + ++ sig_block(SIGUSR1); + fp = xfopen_stdin(fifo_filename); + if (fp != stdin) { + // For named pipes, we want to support this: +@@ -537,8 +588,9 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + // and become an additional writer :) + open(fifo_filename, O_WRONLY); // errors are ignored + } +- + fb_drawprogressbar(0); ++ sig_unblock(SIGUSR1); ++ + // Block on read, waiting for some input. + // Use of <stdio.h> style I/O allows to correctly + // handle a case when we have many buffered lines +@@ -553,12 +605,29 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + #if DEBUG + DEBUG_MESSAGE(itoa(num)); + #endif +- fb_drawprogressbar(num); ++ sig_block(SIGUSR1); ++ if (!G.do_not_draw) ++ fb_drawprogressbar(num); ++ sig_unblock(SIGUSR1); + } + free(num_buf); + } + +- if (bCursorOff) // restore cursor ++ if (G.silent_tty) { ++ usleep(100*1000); ++ ++ ioctl(G.fd_tty_s, VT_RELDISP, 1); ++ ioctl(G.fd_tty_s, KDSETMODE, KD_TEXT); ++ vt.mode = VT_AUTO; ++ vt.waitv = 0; ++ ioctl(G.fd_tty_s, VT_SETMODE, &vt); ++ close(G.fd_tty_s); ++ ++ xioctl(fd_tty0, VT_GETSTATE, &vtstat); ++ if (vtstat.v_active == G.silent_tty) ++ console_make_active(fd_tty0, active_vt); ++ ioctl(fd_tty0, VT_DISALLOCATE, (void *)(ptrdiff_t)G.silent_tty); ++ } else if (bCursorOff) // restore cursor + full_write(STDOUT_FILENO, "\033[?25h", 6); + + return EXIT_SUCCESS; +-- +2.13.2 + diff --git a/legacy/busybox/0005-udhcpc-set-default-discover-retries-to-5.patch b/legacy/busybox/0005-udhcpc-set-default-discover-retries-to-5.patch new file mode 100644 index 000000000..181acdb9a --- /dev/null +++ b/legacy/busybox/0005-udhcpc-set-default-discover-retries-to-5.patch @@ -0,0 +1,35 @@ +From b67940090709f3bbd868557dd4d5317cb807250d Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Thu, 4 Aug 2016 11:08:35 +0200 +Subject: [PATCH 05/16] udhcpc: set default discover retries to 5 + +Some slower nics needs more attempts to get a lease +--- + networking/udhcp/dhcpc.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c +index 55f21c187..cc1d22c8e 100644 +--- a/networking/udhcp/dhcpc.c ++++ b/networking/udhcp/dhcpc.c +@@ -1203,7 +1203,7 @@ static void client_background(void) + //usage: "\n -p FILE Create pidfile" + //usage: "\n -B Request broadcast replies" + //usage: "\n -t N Send up to N discover packets (default 3)" +-//usage: "\n -T SEC Pause between packets (default 3)" ++//usage: "\n -T SEC Pause between packets (default 5)" + //usage: "\n -A SEC Wait if lease is not obtained (default 20)" + //usage: "\n -n Exit if lease is not obtained" + //usage: "\n -q Exit after obtaining lease" +@@ -1247,7 +1247,7 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv) + llist_t *list_x = NULL; + int tryagain_timeout = 20; + int discover_timeout = 3; +- int discover_retries = 3; ++ int discover_retries = 5; + uint32_t server_addr = server_addr; /* for compiler */ + uint32_t requested_ip = 0; + uint32_t xid = xid; /* for compiler */ +-- +2.16.2 + diff --git a/legacy/busybox/0006-fbsplash-support-image-and-bar-alignment-and-positio.patch b/legacy/busybox/0006-fbsplash-support-image-and-bar-alignment-and-positio.patch new file mode 100644 index 000000000..65c423178 --- /dev/null +++ b/legacy/busybox/0006-fbsplash-support-image-and-bar-alignment-and-positio.patch @@ -0,0 +1,185 @@ +From 64e2d2e495f82ef7ccc952bfa4216d1ff8ab3481 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi> +Date: Fri, 21 Nov 2014 16:06:34 +0200 +Subject: [PATCH 06/11] fbsplash: support image and bar alignment and + positioning +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Signed-off-by: Timo Teräs <timo.teras@iki.fi> +--- + miscutils/fbsplash.c | 91 +++++++++++++++++++++++++++++++++++++++++++--------- + 1 file changed, 76 insertions(+), 15 deletions(-) + +diff --git a/miscutils/fbsplash.c b/miscutils/fbsplash.c +index ec5947314..34bbf81f5 100644 +--- a/miscutils/fbsplash.c ++++ b/miscutils/fbsplash.c +@@ -53,6 +53,7 @@ + //usage: "\n -c Hide cursor" + //usage: "\n -d Framebuffer device (default /dev/fb0)" + //usage: "\n -i Config file (var=value):" ++//usage: "\n IMAGE_ALIGN" + //usage: "\n BAR_LEFT,BAR_TOP,BAR_WIDTH,BAR_HEIGHT" + //usage: "\n BAR_R,BAR_G,BAR_B" + //usage: "\n -f Control pipe (else exit after drawing image)" +@@ -71,13 +72,38 @@ + /* If you want logging messages on /tmp/fbsplash.log... */ + #define DEBUG 0 + ++enum { ++ image_align, ++ ++ image_posx, ++ image_posy, ++ bar_width, ++ bar_height, ++ bar_posx, ++ bar_posy, ++ bar_colr, ++ bar_colg, ++ bar_colb, ++ ++ debug ++}; ++ ++#define nimage_align ns[image_align] ++#define nbar_width ns[bar_width] ++#define nbar_height ns[bar_height] ++#define nbar_posx ns[bar_posx] ++#define nbar_posy ns[bar_posy] ++#define nbar_colr ns[bar_colr] ++#define nbar_colg ns[bar_colg] ++#define nbar_colb ns[bar_colb] ++ + struct globals { + #if DEBUG + bool bdebug_messages; // enable/disable logging + FILE *logfile_fd; // log file + #endif + unsigned char *addr; // pointer to framebuffer memory +- unsigned ns[7]; // n-parameters ++ unsigned ns[debug+1]; // n-parameters + const char *image_filename; + int silent_tty, fd_tty_s; + bool do_not_draw; +@@ -94,14 +120,6 @@ struct globals { + SET_PTR_TO_GLOBALS(xzalloc(sizeof(G))); \ + } while (0) + +-#define nbar_width ns[0] // progress bar width +-#define nbar_height ns[1] // progress bar height +-#define nbar_posx ns[2] // progress bar horizontal position +-#define nbar_posy ns[3] // progress bar vertical position +-#define nbar_colr ns[4] // progress bar color red component +-#define nbar_colg ns[5] // progress bar color green component +-#define nbar_colb ns[6] // progress bar color blue component +- + #if DEBUG + #define DEBUG_MESSAGE(strMessage, args...) \ + if (G.bdebug_messages) { \ +@@ -382,7 +400,7 @@ static void fb_drawimage(void) + FILE *theme_file; + char *read_ptr; + unsigned char *pixline; +- unsigned i, j, width, height, line_size; ++ int i, j, width, height, line_size, xoffs, yoffs, xstart; + + if (LONE_DASH(G.image_filename)) { + theme_file = stdin; +@@ -432,18 +450,46 @@ static void fb_drawimage(void) + line_size = width*3; + pixline = xmalloc(line_size); + ++#if 0 + if (width > G.scr_var.xres) + width = G.scr_var.xres; + if (height > G.scr_var.yres) + height = G.scr_var.yres; +- for (j = 0; j < height; j++) { ++#endif ++ ++ xoffs = yoffs = 0; ++ switch (G.nimage_align % 3) { ++ case 1: xoffs = (G.scr_var.xres - width) / 2; break; ++ case 2: xoffs = G.scr_var.xres - width; break; ++ } ++ xstart = 0; ++ if (xoffs < 0) { ++ xstart = -xoffs; ++ width -= xstart; ++ xoffs = 0; ++ } ++ xoffs *= G.bytes_per_pixel; ++ if (width > G.scr_var.xres) ++ width = G.scr_var.xres; ++ ++ switch (G.nimage_align / 3) { ++ case 1: yoffs = (G.scr_var.yres - height) / 2; break; ++ case 2: yoffs = G.scr_var.yres - height; break; ++ } ++ ++ for (j = 0; j < height && yoffs < G.scr_var.yres; j++, yoffs++) { + unsigned char *pixel; + unsigned char *src; + + if (fread(pixline, 1, line_size, theme_file) != line_size) + bb_error_msg_and_die("bad PPM file '%s'", G.image_filename); ++ ++ if (yoffs < 0) ++ continue; ++ + pixel = pixline; +- src = G.addr + j * G.scr_fix.line_length; ++ src = G.addr + yoffs * G.scr_fix.line_length + xoffs; ++ + for (i = 0; i < width; i++) { + unsigned thispix = fb_pixel_value(pixel[0], pixel[1], pixel[2]); + fb_write_pixel(src, thispix); +@@ -462,9 +508,17 @@ static void fb_drawimage(void) + */ + static void init(const char *cfg_filename) + { ++ static const char align_names[] ALIGN1 = ++ "LT\0" "CT\0" "RT\0" ++ "LM\0" "CM\0" "RM\0" ++ "LB\0" "CB\0" "RB\0"; + static const char param_names[] ALIGN1 = ++ "IMAGE_ALIGN\0" ++ ++ "IMAGE_X\0" "IMAGE_Y\0" + "BAR_WIDTH\0" "BAR_HEIGHT\0" + "BAR_LEFT\0" "BAR_TOP\0" ++ + "BAR_R\0" "BAR_G\0" "BAR_B\0" + #if DEBUG + "DEBUG\0" +@@ -474,14 +528,21 @@ static void init(const char *cfg_filename) + parser_t *parser = config_open2(cfg_filename, xfopen_stdin); + while (config_read(parser, token, 2, 2, "#=", + (PARSE_NORMAL | PARSE_MIN_DIE) & ~(PARSE_TRIM | PARSE_COLLAPSE))) { +- unsigned val = xatoi_positive(token[1]); ++ unsigned val; + int i = index_in_strings(param_names, token[0]); ++ + if (i < 0) + bb_error_msg_and_die("syntax error: %s", token[0]); +- if (i >= 0 && i < 7) ++ ++ if (i <= image_align) ++ val = index_in_strings(align_names, token[1]); ++ else ++ val = xatoi_positive(token[1]); ++ ++ if (i < debug) + G.ns[i] = val; + #if DEBUG +- if (i == 7) { ++ if (i == debug) { + G.bdebug_messages = val; + if (G.bdebug_messages) + G.logfile_fd = xfopen_for_write("/tmp/fbsplash.log"); +-- +2.13.2 + diff --git a/legacy/busybox/0006-ping-make-ping-work-without-root-privileges.patch b/legacy/busybox/0006-ping-make-ping-work-without-root-privileges.patch new file mode 100644 index 000000000..630619b4a --- /dev/null +++ b/legacy/busybox/0006-ping-make-ping-work-without-root-privileges.patch @@ -0,0 +1,197 @@ +From 21d74f2989d0046e5b7c586f5a052643d5da8dcc Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Tue, 29 Mar 2016 18:59:22 +0200 +Subject: [PATCH 06/16] ping: make ping work without root privileges + +--- + networking/ping.c | 103 +++++++++++++++++++++++++++++++++++++++++++++--------- + 1 file changed, 87 insertions(+), 16 deletions(-) + +diff --git a/networking/ping.c b/networking/ping.c +index d1d59d545..c0ebc0f9a 100644 +--- a/networking/ping.c ++++ b/networking/ping.c +@@ -163,6 +163,7 @@ enum { + pingsock = 0, + }; + ++static int using_dgram; + static void + #if ENABLE_PING6 + create_icmp_socket(len_and_sockaddr *lsa) +@@ -179,9 +180,23 @@ create_icmp_socket(void) + #endif + sock = socket(AF_INET, SOCK_RAW, 1); /* 1 == ICMP */ + if (sock < 0) { +- if (errno == EPERM) +- bb_error_msg_and_die(bb_msg_perm_denied_are_you_root); +- bb_perror_msg_and_die(bb_msg_can_not_create_raw_socket); ++ if (errno != EPERM) ++ bb_perror_msg_and_die(bb_msg_can_not_create_raw_socket); ++#if defined(__linux__) || defined(__APPLE__) ++ /* We don't have root privileges. Try SOCK_DGRAM instead. ++ * Linux needs net.ipv4.ping_group_range for this to work. ++ * MacOSX allows ICMP_ECHO, ICMP_TSTAMP or ICMP_MASKREQ ++ */ ++#if ENABLE_PING6 ++ if (lsa->u.sa.sa_family == AF_INET6) ++ sock = socket(AF_INET6, SOCK_DGRAM, IPPROTO_ICMPV6); ++ else ++#endif ++ sock = socket(AF_INET, SOCK_DGRAM, 1); /* 1 == ICMP */ ++ if (sock < 0) ++#endif ++ bb_error_msg_and_die(bb_msg_perm_denied_are_you_root); ++ using_dgram = 1; + } + + xmove_fd(sock, pingsock); +@@ -234,10 +249,12 @@ static void ping4(len_and_sockaddr *lsa) + bb_perror_msg("recvfrom"); + continue; + } +- if (c >= 76) { /* ip + icmp */ +- struct iphdr *iphdr = (struct iphdr *) G.packet; ++ if (c >= 76 || using_dgram && (c == 64)) { /* ip + icmp */ ++ if(!using_dgram) { ++ struct iphdr *iphdr = (struct iphdr *) G.packet; + +- pkt = (struct icmp *) (G.packet + (iphdr->ihl << 2)); /* skip ip hdr */ ++ pkt = (struct icmp *) (G.packet + (iphdr->ihl << 2)); /* skip ip hdr */ ++ } else pkt = (struct icmp *) G.packet; + if (pkt->icmp_id != G.myid) + continue; /* not our ping */ + if (pkt->icmp_type == ICMP_ECHOREPLY) +@@ -634,19 +651,21 @@ static void unpack_tail(int sz, uint32_t *tp, + } + static void unpack4(char *buf, int sz, struct sockaddr_in *from) + { +- struct icmp *icmppkt; + struct iphdr *iphdr; ++ struct icmp *icmppkt; + int hlen; + + /* discard if too short */ + if (sz < (datalen + ICMP_MINLEN)) + return; ++ if(!using_dgram) { ++ /* check IP header */ ++ iphdr = (struct iphdr *) buf; ++ hlen = iphdr->ihl << 2; ++ sz -= hlen; ++ icmppkt = (struct icmp *) (buf + hlen); ++ } else icmppkt = (struct icmp *) buf; + +- /* check IP header */ +- iphdr = (struct iphdr *) buf; +- hlen = iphdr->ihl << 2; +- sz -= hlen; +- icmppkt = (struct icmp *) (buf + hlen); + if (icmppkt->icmp_id != myid) + return; /* not our ping */ + +@@ -658,7 +677,7 @@ static void unpack4(char *buf, int sz, struct sockaddr_in *from) + tp = (uint32_t *) icmppkt->icmp_data; + unpack_tail(sz, tp, + inet_ntoa(*(struct in_addr *) &from->sin_addr.s_addr), +- recv_seq, iphdr->ttl); ++ recv_seq, using_dgram ? 42 : iphdr->ttl); + } else if (icmppkt->icmp_type != ICMP_ECHO) { + bb_error_msg("warning: got ICMP %d (%s)", + icmppkt->icmp_type, +@@ -702,11 +721,31 @@ static void ping4(len_and_sockaddr *lsa) + int sockopt; + + pingaddr.sin = lsa->u.sin; +- if (source_lsa) { ++ if (source_lsa && !using_dgram) { + if (setsockopt(pingsock, IPPROTO_IP, IP_MULTICAST_IF, + &source_lsa->u.sa, source_lsa->len)) + bb_error_msg_and_die("can't set multicast source interface"); + xbind(pingsock, &source_lsa->u.sa, source_lsa->len); ++ } else if(using_dgram) { ++ struct sockaddr_in sa; ++ socklen_t sl; ++ ++ sa.sin_family = AF_INET; ++ sa.sin_port = 0; ++ sa.sin_addr.s_addr = source_lsa ? ++ source_lsa->u.sin.sin_addr.s_addr : 0; ++ sl = sizeof(sa); ++ ++ if (bind(pingsock, (struct sockaddr *) &sa, sl) == -1) { ++ perror("bind"); ++ exit(2); ++ } ++ ++ if (getsockname(pingsock, (struct sockaddr *) &sa, &sl) == -1) { ++ perror("getsockname"); ++ exit(2); ++ } ++ myid = sa.sin_port; + } + + /* enable broadcast pings */ +@@ -723,6 +762,15 @@ static void ping4(len_and_sockaddr *lsa) + setsockopt_int(pingsock, IPPROTO_IP, IP_MULTICAST_TTL, opt_ttl); + } + ++ if(using_dgram) { ++ int hold = 65536; ++ if (setsockopt(pingsock, SOL_IP, IP_RECVTTL, (char *)&hold, sizeof(hold))) ++ perror("WARNING: setsockopt(IP_RECVTTL)"); ++ if (setsockopt(pingsock, SOL_IP, IP_RETOPTS, (char *)&hold, sizeof(hold))) ++ perror("WARNING: setsockopt(IP_RETOPTS)"); ++ ++ } ++ + signal(SIGINT, print_stats_and_exit); + + /* start the ping's going ... */ +@@ -756,10 +804,33 @@ static void ping6(len_and_sockaddr *lsa) + char control_buf[CMSG_SPACE(36)]; + + pingaddr.sin6 = lsa->u.sin6; +- if (source_lsa) ++ if (source_lsa && !using_dgram) + xbind(pingsock, &source_lsa->u.sa, source_lsa->len); ++ else if(using_dgram) { ++ struct sockaddr_in6 sa = {0}; ++ socklen_t sl; ++ ++ sa.sin6_family = AF_INET6; ++ sa.sin6_port = 0; ++ if(source_lsa) { ++ memcpy(&sa.sin6_addr, &source_lsa->u.sin6.sin6_addr, sizeof(struct in6_addr)); ++ } ++ sl = sizeof(sa); ++ ++ if (bind(pingsock, (struct sockaddr *) &sa, sl) == -1) { ++ perror("bind"); ++ exit(2); ++ } ++ ++ if (getsockname(pingsock, (struct sockaddr *) &sa, &sl) == -1) { ++ perror("getsockname"); ++ exit(2); ++ } ++ myid = sa.sin6_port; ++ } + + #ifdef ICMP6_FILTER ++ if(!using_dgram) + { + struct icmp6_filter filt; + if (!(option_mask32 & OPT_VERBOSE)) { +@@ -890,7 +961,7 @@ static int common_ping_main(int opt, char **argv) + if (opt & OPT_p) + G.pattern = xstrtou_range(str_p, 16, 0, 255); + +- myid = (uint16_t) getpid(); ++ if (!using_dgram) myid = (uint16_t) getpid(); + hostname = argv[optind]; + #if ENABLE_PING6 + { +-- +2.16.2 + diff --git a/legacy/busybox/0007-depmod-support-generating-kmod-binary-index-files.patch b/legacy/busybox/0007-depmod-support-generating-kmod-binary-index-files.patch new file mode 100644 index 000000000..8b89902de --- /dev/null +++ b/legacy/busybox/0007-depmod-support-generating-kmod-binary-index-files.patch @@ -0,0 +1,516 @@ +From ab4df89615fc2c5726b4ce55546e4dc098211a0b Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi> +Date: Sun, 25 Oct 2015 22:21:41 +0200 +Subject: [PATCH 07/11] depmod: support generating kmod binary index files +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +This allows to use busybox depmod, and run daemons +using libkmod (or even kmod modprobe if needed). + +About +1500 bytes when enabled. This patch merges some +depmod code paths, so when this is disabled it shrinks +the code size a little bit. + +Signed-off-by: Timo Teräs <timo.teras@iki.fi> +--- + modutils/Config.src | 9 ++ + modutils/depmod.c | 281 ++++++++++++++++++++++++++++++++++++++++++---------- + modutils/modprobe.c | 15 --- + modutils/modutils.c | 31 ++++++ + modutils/modutils.h | 16 +++ + 5 files changed, 286 insertions(+), 66 deletions(-) + +diff --git a/modutils/Config.src b/modutils/Config.src +index 9b76c83d2..9e3b9b71e 100644 +--- a/modutils/Config.src ++++ b/modutils/Config.src +@@ -152,6 +152,15 @@ config FEATURE_MODUTILS_ALIAS + + Say Y if unsure. + ++config FEATURE_MODUTILS_BIN ++ bool "Support for the kmod .bin file format" ++ default n ++ depends on DEPMOD && !MODPROBE_SMALL ++ help ++ Generate kmod compatible binary index files for .dep, .alias, ++ .symbols and .builtin files. Allows mixing use of busybox ++ modutils and kmod (binaries and library). ++ + config FEATURE_MODUTILS_SYMBOLS + bool "Support module.symbols file" + default y +diff --git a/modutils/depmod.c b/modutils/depmod.c +index b7965ebd2..73ba7d0f4 100644 +--- a/modutils/depmod.c ++++ b/modutils/depmod.c +@@ -2,7 +2,7 @@ + /* + * depmod - generate modules.dep + * Copyright (c) 2008 Bernhard Reutner-Fischer +- * Copyrihgt (c) 2008 Timo Teras <timo.teras@iki.fi> ++ * Copyrihgt (c) 2008-2015 Timo Teras <timo.teras@iki.fi> + * Copyright (c) 2008 Vladimir Dronnikov + * + * Licensed under GPLv2 or later, see file LICENSE in this source tree. +@@ -26,6 +26,24 @@ + #include "modutils.h" + #include <sys/utsname.h> /* uname() */ + ++#define INDEX_MINCHAR 32 ++#define INDEX_MAXCHAR 128 ++ ++typedef struct index_node { ++ char *prefix; ++ llist_t *values; ++ struct index_node *children[INDEX_MAXCHAR-INDEX_MINCHAR]; ++} index_node; ++ ++struct globals { ++ module_db db; ++ index_node *root_node; ++} FIX_ALIASING; ++#define G (*ptr_to_globals) ++#define INIT_G() do { \ ++ SET_PTR_TO_GLOBALS(xzalloc(sizeof(G))); \ ++} while (0) ++ + /* + * Theory of operation: + * - iterate over all modules and record their full path +@@ -53,18 +71,12 @@ static int FAST_FUNC parse_module(const char *fname, struct stat *sb UNUSED_PARA + + for (ptr = image; ptr < image + len - 10; ptr++) { + if (is_prefixed_with(ptr, "depends=")) { +- char *u; +- + ptr += 8; +- for (u = ptr; *u; u++) +- if (*u == '-') +- *u = '_'; +- ptr += string_to_llist(ptr, &e->deps, ","); ++ string_to_llist(replace_underscores(ptr), &e->deps, ","); + } else if (ENABLE_FEATURE_MODUTILS_ALIAS + && is_prefixed_with(ptr, "alias=") + ) { +- llist_add_to(&e->aliases, xstrdup(ptr + 6)); +- ptr += strlen(ptr); ++ llist_add_to(&e->aliases, replace_underscores(xstrdup(ptr + 6))); + } else if (ENABLE_FEATURE_MODUTILS_SYMBOLS + && is_prefixed_with(ptr, "__ksymtab_") + ) { +@@ -74,9 +86,10 @@ static int FAST_FUNC parse_module(const char *fname, struct stat *sb UNUSED_PARA + ) { + continue; + } +- llist_add_to(&e->symbols, xstrdup(ptr)); +- ptr += strlen(ptr); +- } ++ llist_add_to(&e->symbols, xasprintf("symbol:%s", ptr)); ++ } else ++ continue; ++ ptr += strlen(ptr); + } + free(image); + +@@ -108,12 +121,6 @@ static void order_dep_list(module_db *modules, module_entry *start, llist_t *add + } + } + +-static void xfreopen_write(const char *file, FILE *f) +-{ +- if (freopen(file, "w", f) == NULL) +- bb_perror_msg_and_die("can't open '%s'", file); +-} +- + //usage:#if !ENABLE_MODPROBE_SMALL + //usage:#define depmod_trivial_usage "[-n] [-b BASE] [VERSION] [MODFILES]..." + //usage:#define depmod_full_usage "\n\n" +@@ -167,6 +174,169 @@ enum { + OPT_C = (1 << 9), /* -C,--config etc_modules_conf: ignored */ + }; + ++/* Support for the mod binary index generation */ ++ ++static void index_init(const char *filename) ++{ ++ if (ENABLE_FEATURE_MODUTILS_BIN) { ++ index_node *n; ++ ++ n = xzalloc(sizeof(index_node)); ++ n->prefix = xstrdup(""); ++ G.root_node = n; ++ } ++ ++ if (filename && !(option_mask32 & OPT_n)) { ++ if (freopen(filename, "w", stdout) == NULL) ++ bb_perror_msg_and_die("can't open '%s'", filename); ++ } ++} ++ ++static void index_add(const char *key, char *value, const char *prefix) ++{ ++ if (prefix && *prefix) ++ printf("%s%s %s\n", prefix, key, value); ++ else if (prefix) ++ printf("%s\n", value); ++ ++ if (ENABLE_FEATURE_MODUTILS_BIN) { ++ index_node *cur = G.root_node, *n; ++ unsigned i = 0, j, ch; ++ ++ while (1) { ++ /* Ensure node->prefix is a prefix of &str[i]. ++ * If it is not already, then we must split node. */ ++ for (j = 0; cur->prefix[j]; j++) { ++ ch = cur->prefix[j]; ++ if (ch != key[i+j]) { ++ /* New child is copy of node with prefix[j+1..N] */ ++ n = xzalloc(sizeof(index_node)); ++ n->prefix = xstrdup(&cur->prefix[j+1]); ++ n->values = cur->values; ++ memcpy(n->children, cur->children, sizeof(n->children)); ++ ++ /* Parent has prefix[0..j], child at prefix[j] */ ++ cur->prefix[j] = '\0'; ++ cur->values = NULL; ++ memset(cur->children, 0, sizeof(cur->children)); ++ cur->children[ch-INDEX_MINCHAR] = n; ++ break; ++ } ++ } ++ i += j; ++ ++ ch = key[i]; ++ if (ch == 0) ++ break; ++ ++ if (ch < INDEX_MINCHAR || ch >= INDEX_MAXCHAR) ++ bb_error_msg_and_die("bad module name"); ++ ++ ch -= INDEX_MINCHAR; ++ if (!cur->children[ch]) { ++ n = xzalloc(sizeof(index_node)); ++ cur->children[ch] = n; ++ n->prefix = xstrdup(&key[i+1]); ++ cur = n; ++ break; ++ } ++ ++ /* Descend into child node and continue */ ++ cur = cur->children[ch]; ++ i++; ++ } ++ ++ llist_add_to(&cur->values, value); ++ } ++} ++ ++static uint32_t index_write_node(FILE *out, index_node *n, void (*freeit)(void *data)) ++{ ++ uint32_t child_offs[INDEX_MAXCHAR-INDEX_MINCHAR]; ++ uint32_t offset; ++ uint8_t first = 255, last = 0; ++ unsigned i; ++ ++ for (i = 0; i < INDEX_MAXCHAR-INDEX_MINCHAR; i++) { ++ child_offs[i] = 0; ++ if (!n->children[i]) ++ continue; ++ child_offs[i] = index_write_node(out, n->children[i], freeit); ++ if (first > INDEX_MAXCHAR) ++ first = i; ++ last = i; ++ } ++ ++ offset = ftell(out); ++ ++ if (n->prefix[0]) { ++ fputs(n->prefix, out); ++ fputc('\0', out); ++ offset |= INDEX_NODE_PREFIX; ++ } ++ ++ if (first < INDEX_MAXCHAR) { ++ fputc(first + INDEX_MINCHAR, out); ++ fputc(last + INDEX_MINCHAR, out); ++ fwrite(child_offs + first, sizeof(uint32_t), last - first + 1, out); ++ offset |= INDEX_NODE_CHILDS; ++ } ++ ++ if (n->values) { ++ const llist_t *v; ++ unsigned int cnt; ++ uint32_t u; ++ ++ n->values = llist_rev(n->values); ++ for (v = n->values, cnt = 0; v != NULL; v = v->link, cnt++); ++ u = htonl(cnt); ++ fwrite(&u, sizeof(u), 1, out); ++ for (v = n->values, cnt = 0; v != NULL; v = v->link, cnt++) { ++ u = htonl(cnt); ++ fwrite(&u, sizeof(u), 1, out); ++ fputs(v->data, out); ++ fputc('\0', out); ++ } ++ offset |= INDEX_NODE_VALUES; ++ } ++ ++ llist_free(n->values, freeit); ++ free(n->prefix); ++ free(n); ++ ++ return htonl(offset); ++} ++ ++static void index_dump(const char *filename, int deps_file) ++{ ++ if (ENABLE_FEATURE_MODUTILS_BIN) { ++ FILE *out; ++ uint32_t header[3] = { ++ htonl(INDEX_MAGIC), ++ htonl(INDEX_VERSION), ++ }; ++ ++ if (option_mask32 & OPT_n) ++ filename = "/dev/null"; ++ else ++ filename = xasprintf("tmp.%s.bin", filename); ++ ++ out = xfopen_for_write(filename); ++ fwrite(header, sizeof(uint32_t), 3, out); ++ header[2] = index_write_node(out, G.root_node, deps_file ? free : 0); ++ rewind(out); ++ G.root_node = NULL; ++ fwrite(header, sizeof(uint32_t), 3, out); ++ if (fclose(out)) { ++ remove(filename); ++ bb_error_msg_and_die(bb_msg_write_error); ++ } ++ /* .bin files are mmap'ed; not renaming it may crash ++ * long standing daemon using libkmod */ ++ rename_or_warn(filename, filename + 4); ++ } ++} ++ + int depmod_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; + int depmod_main(int argc UNUSED_PARAM, char **argv) + { +@@ -178,6 +348,8 @@ int depmod_main(int argc UNUSED_PARAM, char **argv) + unsigned i; + int tmp; + ++ INIT_G(); ++ + getopt32(argv, "aAb:eF:nruqC:", &moddir_base, NULL, NULL); + argv += optind; + +@@ -210,53 +382,60 @@ int depmod_main(int argc UNUSED_PARAM, char **argv) + } + + /* Generate dependency and alias files */ +- if (!(option_mask32 & OPT_n)) +- xfreopen_write(CONFIG_DEFAULT_DEPMOD_FILE, stdout); +- ++ index_init(CONFIG_DEFAULT_DEPMOD_FILE); + moddb_foreach_module(&modules, m, i) { +- printf("%s:", m->name); +- ++ char *buf = xasprintf("%s:", m->name); + order_dep_list(&modules, m, m->deps); ++ + while (m->dnext != m) { + dep = m->dnext; +- printf(" %s", dep->name); +- ++ buf = gather_options_str(buf, dep->name); + /* unlink current entry */ + dep->dnext->dprev = dep->dprev; + dep->dprev->dnext = dep->dnext; + dep->dnext = dep->dprev = dep; + } +- bb_putchar('\n'); ++ index_add(m->modname, buf, ""); + } +- +-#if ENABLE_FEATURE_MODUTILS_ALIAS +- if (!(option_mask32 & OPT_n)) +- xfreopen_write("modules.alias", stdout); +- moddb_foreach_module(&modules, m, i) { +- while (m->aliases) { +- /* +- * Last word used to be a basename +- * (filename with path and .ko.* stripped) +- * at the time of module-init-tools 3.4. +- * kmod v.12 uses module name, i.e., s/-/_/g. +- */ +- printf("alias %s %s\n", +- (char*)llist_pop(&m->aliases), +- m->modname); ++ index_dump(CONFIG_DEFAULT_DEPMOD_FILE, 1); ++ ++ if (ENABLE_FEATURE_MODUTILS_ALIAS) { ++ index_init("modules.alias"); ++ moddb_foreach_module(&modules, m, i) { ++ while (m->aliases) { ++ /* ++ * Last word used to be a basename ++ * (filename with path and .ko.* stripped) ++ * at the time of module-init-tools 3.4. ++ * kmod v.12 uses module name, i.e., s/-/_/g. ++ */ ++ index_add((char*)llist_pop(&m->aliases), m->modname, "alias "); ++ } + } ++ index_dump("modules.alias", 0); + } +-#endif +-#if ENABLE_FEATURE_MODUTILS_SYMBOLS +- if (!(option_mask32 & OPT_n)) +- xfreopen_write("modules.symbols", stdout); +- moddb_foreach_module(&modules, m, i) { +- while (m->symbols) { +- printf("alias symbol:%s %s\n", +- (char*)llist_pop(&m->symbols), +- m->modname); ++ if (ENABLE_FEATURE_MODUTILS_SYMBOLS) { ++ index_init("modules.symbols"); ++ moddb_foreach_module(&modules, m, i) { ++ while (m->symbols) { ++ index_add((char*)llist_pop(&m->symbols), m->modname, "alias "); ++ } ++ } ++ index_dump("modules.symbols", 0); ++ } ++ if (ENABLE_FEATURE_MODUTILS_BIN) { ++ char line[PATH_MAX], modname[MODULE_NAME_LEN]; ++ FILE *in; ++ ++ index_init(NULL); ++ in = xfopen_for_read("modules.builtin"); ++ while (fgets(line, sizeof(line), in) != NULL) { ++ filename2modname(line, modname); ++ index_add(modname, (char *) "", 0); + } ++ fclose(in); ++ index_dump("modules.builtin", 0); + } +-#endif + + if (ENABLE_FEATURE_CLEAN_UP) + moddb_free(&modules); +diff --git a/modutils/modprobe.c b/modutils/modprobe.c +index 51ede9204..d1fcc0b7f 100644 +--- a/modutils/modprobe.c ++++ b/modutils/modprobe.c +@@ -192,21 +192,6 @@ struct globals { + + static int read_config(const char *path); + +-static char *gather_options_str(char *opts, const char *append) +-{ +- /* Speed-optimized. We call gather_options_str many times. */ +- if (append) { +- if (opts == NULL) { +- opts = xstrdup(append); +- } else { +- int optlen = strlen(opts); +- opts = xrealloc(opts, optlen + strlen(append) + 2); +- sprintf(opts + optlen, " %s", append); +- } +- } +- return opts; +-} +- + static struct module_entry *get_or_add_modentry(const char *module) + { + return moddb_get_or_create(&G.db, module); +diff --git a/modutils/modutils.c b/modutils/modutils.c +index 6f7cd9721..257089af4 100644 +--- a/modutils/modutils.c ++++ b/modutils/modutils.c +@@ -66,6 +66,21 @@ void FAST_FUNC moddb_free(module_db *db) + } + } + ++char * FAST_FUNC gather_options_str(char *opts, const char *append) ++{ ++ /* Speed-optimized. We call gather_options_str many times. */ ++ if (append) { ++ if (opts == NULL) { ++ opts = xstrdup(append); ++ } else { ++ int optlen = strlen(opts); ++ opts = xrealloc(opts, optlen + strlen(append) + 2); ++ sprintf(opts + optlen, " %s", append); ++ } ++ } ++ return opts; ++} ++ + void FAST_FUNC replace(char *s, char what, char with) + { + while (*s) { +@@ -75,6 +90,22 @@ void FAST_FUNC replace(char *s, char what, char with) + } + } + ++char* FAST_FUNC replace_underscores(char *s) ++{ ++ int i; ++ for (i = 0; s[i]; i++) { ++ switch (s[i]) { ++ case '-': ++ s[i] = '_'; ++ break; ++ case '[': ++ i += strcspn(&s[i], "]"); ++ break; ++ } ++ } ++ return s; ++} ++ + int FAST_FUNC string_to_llist(char *string, llist_t **llist, const char *delim) + { + char *tok; +diff --git a/modutils/modutils.h b/modutils/modutils.h +index 4a702e97c..73e816028 100644 +--- a/modutils/modutils.h ++++ b/modutils/modutils.h +@@ -18,6 +18,20 @@ PUSH_AND_SET_FUNCTION_VISIBILITY_TO_HIDDEN + #define MODULE_NAME_LEN 256 + #define MODULE_HASH_SIZE 256 + ++/* .bin index format definitions */ ++#define INDEX_MAGIC 0xB007F457 ++#define INDEX_VERSION_MAJOR 0x0002 ++#define INDEX_VERSION_MINOR 0x0001 ++#define INDEX_VERSION ((INDEX_VERSION_MAJOR<<16)|INDEX_VERSION_MINOR) ++ ++enum node_offset { ++ INDEX_NODE_FLAGS = 0xF0000000, /* Flags in high nibble */ ++ INDEX_NODE_PREFIX = 0x80000000, ++ INDEX_NODE_VALUES = 0x40000000, ++ INDEX_NODE_CHILDS = 0x20000000, ++ INDEX_NODE_MASK = 0x0FFFFFFF, /* Offset value */ ++}; ++ + typedef struct module_entry { + struct module_entry *next; + char *name, *modname; +@@ -47,7 +61,9 @@ module_entry *moddb_get(module_db *db, const char *s) FAST_FUNC; + module_entry *moddb_get_or_create(module_db *db, const char *s) FAST_FUNC; + void moddb_free(module_db *db) FAST_FUNC; + ++char *gather_options_str(char *opts, const char *append) FAST_FUNC; + void replace(char *s, char what, char with) FAST_FUNC; ++char *replace_underscores(char *s) FAST_FUNC; + int string_to_llist(char *string, llist_t **llist, const char *delim) FAST_FUNC; + char *filename2modname(const char *filename, char *modname) FAST_FUNC; + #if ENABLE_FEATURE_CMDLINE_MODULE_OPTIONS +-- +2.13.2 + diff --git a/legacy/busybox/0007-fbsplash-support-console-switching.patch b/legacy/busybox/0007-fbsplash-support-console-switching.patch new file mode 100644 index 000000000..ef226d009 --- /dev/null +++ b/legacy/busybox/0007-fbsplash-support-console-switching.patch @@ -0,0 +1,182 @@ +From 377e2f20c1034de1195fd900fc637821952cfa49 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi> +Date: Mon, 24 Sep 2012 07:58:29 +0300 +Subject: [PATCH 07/16] fbsplash: support console switching + +--- + miscutils/fbsplash.c | 82 +++++++++++++++++++++++++++++++++++++++++++++++----- + 1 file changed, 75 insertions(+), 7 deletions(-) + +diff --git a/miscutils/fbsplash.c b/miscutils/fbsplash.c +index 5b2e5ac56..bc80f728c 100644 +--- a/miscutils/fbsplash.c ++++ b/miscutils/fbsplash.c +@@ -47,7 +47,7 @@ + //kbuild:lib-$(CONFIG_FBSPLASH) += fbsplash.o + + //usage:#define fbsplash_trivial_usage +-//usage: "-s IMGFILE [-c] [-d DEV] [-i INIFILE] [-f CMD]" ++//usage: "-s IMGFILE [-c] [-d DEV] [-i INIFILE] [-f CMD] [-T tty]" + //usage:#define fbsplash_full_usage "\n\n" + //usage: " -s Image" + //usage: "\n -c Hide cursor" +@@ -57,11 +57,17 @@ + //usage: "\n BAR_R,BAR_G,BAR_B" + //usage: "\n -f Control pipe (else exit after drawing image)" + //usage: "\n commands: 'NN' (% for progress bar) or 'exit'" ++//usage: "\n -T Switch to TTY to hide all console messages" + + #include "libbb.h" + #include "common_bufsiz.h" + #include <linux/fb.h> + ++#include <sys/vt.h> ++#include <sys/ioctl.h> ++#include <linux/tiocl.h> ++#include <linux/kd.h> ++ + /* If you want logging messages on /tmp/fbsplash.log... */ + #define DEBUG 0 + +@@ -75,6 +81,8 @@ struct globals { + unsigned char *addr; // pointer to framebuffer memory + unsigned ns[7]; // n-parameters + const char *image_filename; ++ int silent_tty, fd_tty_s; ++ bool do_not_draw; + struct fb_var_screeninfo scr_var; + struct fb_fix_screeninfo scr_fix; + unsigned bytes_per_pixel; +@@ -485,6 +493,11 @@ static void init(const char *cfg_filename) + config_close(parser); + } + ++static void sighandler(int sig) ++{ ++ ioctl(G.fd_tty_s, VT_RELDISP, sig == SIGUSR1 ? 1 : 2); ++ G.do_not_draw = (sig != SIGUSR2); ++} + + int fbsplash_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; + int fbsplash_main(int argc UNUSED_PARAM, char **argv) +@@ -494,6 +507,9 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + char *num_buf; + unsigned num; + bool bCursorOff; ++ int fd_tty0, active_vt; ++ struct vt_stat vtstat; ++ struct vt_mode vt; + + INIT_G(); + +@@ -501,8 +517,9 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + fb_device = "/dev/fb0"; + cfg_filename = NULL; + fifo_filename = NULL; +- bCursorOff = 1 & getopt32(argv, "cs:d:i:f:", +- &G.image_filename, &fb_device, &cfg_filename, &fifo_filename); ++ bCursorOff = 1 & getopt32(argv, "cs:d:i:f:T:", ++ &G.image_filename, &fb_device, &cfg_filename, &fifo_filename, ++ &G.silent_tty); + + // parse configuration file + if (cfg_filename) +@@ -512,11 +529,43 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + if (!G.image_filename) + bb_show_usage(); + ++ fd_tty0 = get_console_fd_or_die(); ++ if (G.silent_tty) { ++ char buf[16]; ++ ++ /* Initialize TTY */ ++ bb_signals((1LL << SIGUSR1) | (1LL << SIGUSR2), sighandler); ++ snprintf(buf, sizeof(buf), "/dev/tty%d", G.silent_tty); ++ G.fd_tty_s = xopen(buf, O_RDWR | O_NOCTTY); ++ ++ /* Activate TTY */ ++ xioctl(fd_tty0, VT_GETSTATE, &vtstat); ++ active_vt = vtstat.v_active; ++ console_make_active(fd_tty0, G.silent_tty); ++ ++ /* Get notifications on console changes */ ++ vt.mode = VT_PROCESS; ++ vt.waitv = 0; ++ vt.relsig = SIGUSR1; ++ vt.acqsig = SIGUSR2; ++ ioctl(G.fd_tty_s, VT_SETMODE, &vt); ++ ++ /* Redirect all kernel messages to tty1 so that they don't get ++ * printed over our silent splash image. And clear it. */ ++ buf[0] = TIOCL_SETKMSGREDIRECT; ++ buf[1] = 1; ++ ioctl(G.fd_tty_s, TIOCLINUX, buf); ++ full_write(G.fd_tty_s, "\e[H\e[2J" "\e[?17;0c", 7+8); ++ ioctl(G.fd_tty_s, KDSETMODE, KD_GRAPHICS); ++ } else { ++ G.fd_tty_s = STDOUT_FILENO; ++ } ++ + fb_open(fb_device); + + if (fifo_filename && bCursorOff) { + // hide cursor (BEFORE any fb ops) +- full_write(STDOUT_FILENO, ESC"[?25l", 6); ++ full_write(G.fd_tty_s, ESC"[?25l", 6); + } + + fb_drawimage(); +@@ -524,6 +573,7 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + if (!fifo_filename) + return EXIT_SUCCESS; + ++ sig_block(SIGUSR1); + fp = xfopen_stdin(fifo_filename); + if (fp != stdin) { + // For named pipes, we want to support this: +@@ -539,8 +589,9 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + // and become an additional writer :) + open(fifo_filename, O_WRONLY); // errors are ignored + } +- + fb_drawprogressbar(0); ++ sig_unblock(SIGUSR1); ++ + // Block on read, waiting for some input. + // Use of <stdio.h> style I/O allows to correctly + // handle a case when we have many buffered lines +@@ -555,12 +606,29 @@ int fbsplash_main(int argc UNUSED_PARAM, char **argv) + #if DEBUG + DEBUG_MESSAGE(itoa(num)); + #endif +- fb_drawprogressbar(num); ++ sig_block(SIGUSR1); ++ if (!G.do_not_draw) ++ fb_drawprogressbar(num); ++ sig_unblock(SIGUSR1); + } + free(num_buf); + } + +- if (bCursorOff) // restore cursor ++ if (G.silent_tty) { ++ usleep(100*1000); ++ ++ ioctl(G.fd_tty_s, VT_RELDISP, 1); ++ ioctl(G.fd_tty_s, KDSETMODE, KD_TEXT); ++ vt.mode = VT_AUTO; ++ vt.waitv = 0; ++ ioctl(G.fd_tty_s, VT_SETMODE, &vt); ++ close(G.fd_tty_s); ++ ++ xioctl(fd_tty0, VT_GETSTATE, &vtstat); ++ if (vtstat.v_active == G.silent_tty) ++ console_make_active(fd_tty0, active_vt); ++ ioctl(fd_tty0, VT_DISALLOCATE, (void *)(ptrdiff_t)G.silent_tty); ++ } else if (bCursorOff) // restore cursor + full_write(STDOUT_FILENO, ESC"[?25h", 6); + + return EXIT_SUCCESS; +-- +2.16.2 + diff --git a/legacy/busybox/0008-diff-add-support-for-no-dereference.patch b/legacy/busybox/0008-diff-add-support-for-no-dereference.patch new file mode 100644 index 000000000..95063a863 --- /dev/null +++ b/legacy/busybox/0008-diff-add-support-for-no-dereference.patch @@ -0,0 +1,63 @@ +From d70be9891718ffb94ea9946cc3540b1b62eced77 Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Fri, 25 Jul 2014 15:28:33 +0200 +Subject: [PATCH 08/11] diff: add support for --no-dereference + +Add flag for not following symlinks when recursing + +function old new delta +.rodata 7934 7967 +33 +diff_longopts 253 270 +17 +packed_usage 1704 1720 +16 +diff_main 1665 1662 -3 +------------------------------------------------------------------------------ +(add/remove: 0/0 grow/shrink: 3/1 up/down: 66/-3) Total: 63 bytes + +Signed-off-by: Natanael Copa <ncopa@alpinelinux.org> +--- + editors/diff.c | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +diff --git a/editors/diff.c b/editors/diff.c +index 7687518f3..f07cafb19 100644 +--- a/editors/diff.c ++++ b/editors/diff.c +@@ -115,6 +115,9 @@ + //usage: "\n -N Treat absent files as empty" + //usage: "\n -q Output only whether files differ" + //usage: "\n -r Recurse" ++//usage: IF_LONG_OPTS( ++//usage: "\n --no-dereference Don't follow symlinks" ++//usage: ) + //usage: "\n -S Start with FILE when comparing directories" + //usage: "\n -T Make tabs line up by prefixing a tab when necessary" + //usage: "\n -s Report when two files are the same" +@@ -156,6 +159,7 @@ enum { /* Commandline flags */ + FLAG_p, /* not implemented */ + FLAG_B, + FLAG_E, /* not implemented */ ++ FLAG_no_deref, + }; + #define FLAG(x) (1 << FLAG_##x) + +@@ -869,7 +873,8 @@ static void diffdir(char *p[2], const char *s_start) + * Using list.len to specify its length, + * add_to_dirlist will remove it. */ + list[i].len = strlen(p[i]); +- recursive_action(p[i], ACTION_RECURSE | ACTION_FOLLOWLINKS, ++ recursive_action(p[i], ACTION_RECURSE | ++ ((option_mask32 & FLAG(no_deref)) ? 0 : ACTION_FOLLOWLINKS), + add_to_dirlist, skip_dir, &list[i], 0); + /* Sort dl alphabetically. + * GNU diff does this ignoring any number of trailing dots. +@@ -966,6 +971,7 @@ static const char diff_longopts[] ALIGN1 = + "report-identical-files\0" No_argument "s" + "starting-file\0" Required_argument "S" + "minimal\0" No_argument "d" ++ "no-dereference\0" No_argument "\xff" + ; + #endif + +-- +2.13.2 + diff --git a/legacy/busybox/0008-fbsplash-support-image-and-bar-alignment-and-positio.patch b/legacy/busybox/0008-fbsplash-support-image-and-bar-alignment-and-positio.patch new file mode 100644 index 000000000..b0cb5cc3d --- /dev/null +++ b/legacy/busybox/0008-fbsplash-support-image-and-bar-alignment-and-positio.patch @@ -0,0 +1,181 @@ +From 97fcb49bfbe74fa17a52e63b2196d8a5c3b27d93 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi> +Date: Fri, 21 Nov 2014 16:06:34 +0200 +Subject: [PATCH 08/16] fbsplash: support image and bar alignment and + positioning + +--- + miscutils/fbsplash.c | 91 +++++++++++++++++++++++++++++++++++++++++++--------- + 1 file changed, 76 insertions(+), 15 deletions(-) + +diff --git a/miscutils/fbsplash.c b/miscutils/fbsplash.c +index bc80f728c..9089131b8 100644 +--- a/miscutils/fbsplash.c ++++ b/miscutils/fbsplash.c +@@ -53,6 +53,7 @@ + //usage: "\n -c Hide cursor" + //usage: "\n -d Framebuffer device (default /dev/fb0)" + //usage: "\n -i Config file (var=value):" ++//usage: "\n IMAGE_ALIGN" + //usage: "\n BAR_LEFT,BAR_TOP,BAR_WIDTH,BAR_HEIGHT" + //usage: "\n BAR_R,BAR_G,BAR_B" + //usage: "\n -f Control pipe (else exit after drawing image)" +@@ -73,13 +74,38 @@ + + #define ESC "\033" + ++enum { ++ image_align, ++ ++ image_posx, ++ image_posy, ++ bar_width, ++ bar_height, ++ bar_posx, ++ bar_posy, ++ bar_colr, ++ bar_colg, ++ bar_colb, ++ ++ debug ++}; ++ ++#define nimage_align ns[image_align] ++#define nbar_width ns[bar_width] ++#define nbar_height ns[bar_height] ++#define nbar_posx ns[bar_posx] ++#define nbar_posy ns[bar_posy] ++#define nbar_colr ns[bar_colr] ++#define nbar_colg ns[bar_colg] ++#define nbar_colb ns[bar_colb] ++ + struct globals { + #if DEBUG + bool bdebug_messages; // enable/disable logging + FILE *logfile_fd; // log file + #endif + unsigned char *addr; // pointer to framebuffer memory +- unsigned ns[7]; // n-parameters ++ unsigned ns[debug+1]; // n-parameters + const char *image_filename; + int silent_tty, fd_tty_s; + bool do_not_draw; +@@ -96,14 +122,6 @@ struct globals { + SET_PTR_TO_GLOBALS(xzalloc(sizeof(G))); \ + } while (0) + +-#define nbar_width ns[0] // progress bar width +-#define nbar_height ns[1] // progress bar height +-#define nbar_posx ns[2] // progress bar horizontal position +-#define nbar_posy ns[3] // progress bar vertical position +-#define nbar_colr ns[4] // progress bar color red component +-#define nbar_colg ns[5] // progress bar color green component +-#define nbar_colb ns[6] // progress bar color blue component +- + #if DEBUG + #define DEBUG_MESSAGE(strMessage, args...) \ + if (G.bdebug_messages) { \ +@@ -384,7 +402,7 @@ static void fb_drawimage(void) + FILE *theme_file; + char *read_ptr; + unsigned char *pixline; +- unsigned i, j, width, height, line_size; ++ int i, j, width, height, line_size, xoffs, yoffs, xstart; + + if (LONE_DASH(G.image_filename)) { + theme_file = stdin; +@@ -434,18 +452,46 @@ static void fb_drawimage(void) + line_size = width*3; + pixline = xmalloc(line_size); + ++#if 0 + if (width > G.scr_var.xres) + width = G.scr_var.xres; + if (height > G.scr_var.yres) + height = G.scr_var.yres; +- for (j = 0; j < height; j++) { ++#endif ++ ++ xoffs = yoffs = 0; ++ switch (G.nimage_align % 3) { ++ case 1: xoffs = (G.scr_var.xres - width) / 2; break; ++ case 2: xoffs = G.scr_var.xres - width; break; ++ } ++ xstart = 0; ++ if (xoffs < 0) { ++ xstart = -xoffs; ++ width -= xstart; ++ xoffs = 0; ++ } ++ xoffs *= G.bytes_per_pixel; ++ if (width > G.scr_var.xres) ++ width = G.scr_var.xres; ++ ++ switch (G.nimage_align / 3) { ++ case 1: yoffs = (G.scr_var.yres - height) / 2; break; ++ case 2: yoffs = G.scr_var.yres - height; break; ++ } ++ ++ for (j = 0; j < height && yoffs < G.scr_var.yres; j++, yoffs++) { + unsigned char *pixel; + unsigned char *src; + + if (fread(pixline, 1, line_size, theme_file) != line_size) + bb_error_msg_and_die("bad PPM file '%s'", G.image_filename); ++ ++ if (yoffs < 0) ++ continue; ++ + pixel = pixline; +- src = G.addr + j * G.scr_fix.line_length; ++ src = G.addr + yoffs * G.scr_fix.line_length + xoffs; ++ + for (i = 0; i < width; i++) { + unsigned thispix = fb_pixel_value(pixel[0], pixel[1], pixel[2]); + fb_write_pixel(src, thispix); +@@ -464,9 +510,17 @@ static void fb_drawimage(void) + */ + static void init(const char *cfg_filename) + { ++ static const char align_names[] ALIGN1 = ++ "LT\0" "CT\0" "RT\0" ++ "LM\0" "CM\0" "RM\0" ++ "LB\0" "CB\0" "RB\0"; + static const char param_names[] ALIGN1 = ++ "IMAGE_ALIGN\0" ++ ++ "IMAGE_X\0" "IMAGE_Y\0" + "BAR_WIDTH\0" "BAR_HEIGHT\0" + "BAR_LEFT\0" "BAR_TOP\0" ++ + "BAR_R\0" "BAR_G\0" "BAR_B\0" + #if DEBUG + "DEBUG\0" +@@ -476,14 +530,21 @@ static void init(const char *cfg_filename) + parser_t *parser = config_open2(cfg_filename, xfopen_stdin); + while (config_read(parser, token, 2, 2, "#=", + (PARSE_NORMAL | PARSE_MIN_DIE) & ~(PARSE_TRIM | PARSE_COLLAPSE))) { +- unsigned val = xatoi_positive(token[1]); ++ unsigned val; + int i = index_in_strings(param_names, token[0]); ++ + if (i < 0) + bb_error_msg_and_die("syntax error: %s", token[0]); +- if (i >= 0 && i < 7) ++ ++ if (i <= image_align) ++ val = index_in_strings(align_names, token[1]); ++ else ++ val = xatoi_positive(token[1]); ++ ++ if (i < debug) + G.ns[i] = val; + #if DEBUG +- if (i == 7) { ++ if (i == debug) { + G.bdebug_messages = val; + if (G.bdebug_messages) + G.logfile_fd = xfopen_for_write("/tmp/fbsplash.log"); +-- +2.16.2 + diff --git a/legacy/busybox/0009-depmod-support-generating-kmod-binary-index-files.patch b/legacy/busybox/0009-depmod-support-generating-kmod-binary-index-files.patch new file mode 100644 index 000000000..2034f5c88 --- /dev/null +++ b/legacy/busybox/0009-depmod-support-generating-kmod-binary-index-files.patch @@ -0,0 +1,510 @@ +From d13cb44f10d730eeac83340f71ea95b6faa0c142 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Timo=20Ter=C3=A4s?= <timo.teras@iki.fi> +Date: Sun, 25 Oct 2015 22:21:41 +0200 +Subject: [PATCH 09/16] depmod: support generating kmod binary index files + +This allows to use busybox depmod, and run daemons using libkmod (or +even kmod modprobe if needed). + +About +1500 bytes when enabled. This patch merges some depmod code +paths, so when this is disabled it shrinks the code size a little bit. +--- + modutils/Config.src | 9 ++ + modutils/depmod.c | 281 ++++++++++++++++++++++++++++++++++++++++++---------- + modutils/modprobe.c | 15 --- + modutils/modutils.c | 31 ++++++ + modutils/modutils.h | 16 +++ + 5 files changed, 286 insertions(+), 66 deletions(-) + +diff --git a/modutils/Config.src b/modutils/Config.src +index e413702bb..1be7434a5 100644 +--- a/modutils/Config.src ++++ b/modutils/Config.src +@@ -152,6 +152,15 @@ config FEATURE_MODUTILS_ALIAS + + Say Y if unsure. + ++config FEATURE_MODUTILS_BIN ++ bool "Support for the kmod .bin file format" ++ default n ++ depends on DEPMOD && !MODPROBE_SMALL ++ help ++ Generate kmod compatible binary index files for .dep, .alias, ++ .symbols and .builtin files. Allows mixing use of busybox ++ modutils and kmod (binaries and library). ++ + config FEATURE_MODUTILS_SYMBOLS + bool "Support module.symbols file" + default y +diff --git a/modutils/depmod.c b/modutils/depmod.c +index 004c67a11..05c1a9bce 100644 +--- a/modutils/depmod.c ++++ b/modutils/depmod.c +@@ -2,7 +2,7 @@ + /* + * depmod - generate modules.dep + * Copyright (c) 2008 Bernhard Reutner-Fischer +- * Copyrihgt (c) 2008 Timo Teras <timo.teras@iki.fi> ++ * Copyrihgt (c) 2008-2015 Timo Teras <timo.teras@iki.fi> + * Copyright (c) 2008 Vladimir Dronnikov + * + * Licensed under GPLv2 or later, see file LICENSE in this source tree. +@@ -26,6 +26,24 @@ + #include "modutils.h" + #include <sys/utsname.h> /* uname() */ + ++#define INDEX_MINCHAR 32 ++#define INDEX_MAXCHAR 128 ++ ++typedef struct index_node { ++ char *prefix; ++ llist_t *values; ++ struct index_node *children[INDEX_MAXCHAR-INDEX_MINCHAR]; ++} index_node; ++ ++struct globals { ++ module_db db; ++ index_node *root_node; ++} FIX_ALIASING; ++#define G (*ptr_to_globals) ++#define INIT_G() do { \ ++ SET_PTR_TO_GLOBALS(xzalloc(sizeof(G))); \ ++} while (0) ++ + /* + * Theory of operation: + * - iterate over all modules and record their full path +@@ -53,18 +71,12 @@ static int FAST_FUNC parse_module(const char *fname, struct stat *sb UNUSED_PARA + + for (ptr = image; ptr < image + len - 10; ptr++) { + if (is_prefixed_with(ptr, "depends=")) { +- char *u; +- + ptr += 8; +- for (u = ptr; *u; u++) +- if (*u == '-') +- *u = '_'; +- ptr += string_to_llist(ptr, &e->deps, ","); ++ string_to_llist(replace_underscores(ptr), &e->deps, ","); + } else if (ENABLE_FEATURE_MODUTILS_ALIAS + && is_prefixed_with(ptr, "alias=") + ) { +- llist_add_to(&e->aliases, xstrdup(ptr + 6)); +- ptr += strlen(ptr); ++ llist_add_to(&e->aliases, replace_underscores(xstrdup(ptr + 6))); + } else if (ENABLE_FEATURE_MODUTILS_SYMBOLS + && is_prefixed_with(ptr, "__ksymtab_") + ) { +@@ -74,9 +86,10 @@ static int FAST_FUNC parse_module(const char *fname, struct stat *sb UNUSED_PARA + ) { + continue; + } +- llist_add_to(&e->symbols, xstrdup(ptr)); +- ptr += strlen(ptr); +- } ++ llist_add_to(&e->symbols, xasprintf("symbol:%s", ptr)); ++ } else ++ continue; ++ ptr += strlen(ptr); + } + free(image); + +@@ -108,12 +121,6 @@ static void order_dep_list(module_db *modules, module_entry *start, llist_t *add + } + } + +-static void xfreopen_write(const char *file, FILE *f) +-{ +- if (freopen(file, "w", f) == NULL) +- bb_perror_msg_and_die("can't open '%s'", file); +-} +- + //usage:#if !ENABLE_MODPROBE_SMALL + //usage:#define depmod_trivial_usage "[-n] [-b BASE] [VERSION] [MODFILES]..." + //usage:#define depmod_full_usage "\n\n" +@@ -167,6 +174,169 @@ enum { + OPT_C = (1 << 9), /* -C,--config etc_modules_conf: ignored */ + }; + ++/* Support for the mod binary index generation */ ++ ++static void index_init(const char *filename) ++{ ++ if (ENABLE_FEATURE_MODUTILS_BIN) { ++ index_node *n; ++ ++ n = xzalloc(sizeof(index_node)); ++ n->prefix = xstrdup(""); ++ G.root_node = n; ++ } ++ ++ if (filename && !(option_mask32 & OPT_n)) { ++ if (freopen(filename, "w", stdout) == NULL) ++ bb_perror_msg_and_die("can't open '%s'", filename); ++ } ++} ++ ++static void index_add(const char *key, char *value, const char *prefix) ++{ ++ if (prefix && *prefix) ++ printf("%s%s %s\n", prefix, key, value); ++ else if (prefix) ++ printf("%s\n", value); ++ ++ if (ENABLE_FEATURE_MODUTILS_BIN) { ++ index_node *cur = G.root_node, *n; ++ unsigned i = 0, j, ch; ++ ++ while (1) { ++ /* Ensure node->prefix is a prefix of &str[i]. ++ * If it is not already, then we must split node. */ ++ for (j = 0; cur->prefix[j]; j++) { ++ ch = cur->prefix[j]; ++ if (ch != key[i+j]) { ++ /* New child is copy of node with prefix[j+1..N] */ ++ n = xzalloc(sizeof(index_node)); ++ n->prefix = xstrdup(&cur->prefix[j+1]); ++ n->values = cur->values; ++ memcpy(n->children, cur->children, sizeof(n->children)); ++ ++ /* Parent has prefix[0..j], child at prefix[j] */ ++ cur->prefix[j] = '\0'; ++ cur->values = NULL; ++ memset(cur->children, 0, sizeof(cur->children)); ++ cur->children[ch-INDEX_MINCHAR] = n; ++ break; ++ } ++ } ++ i += j; ++ ++ ch = key[i]; ++ if (ch == 0) ++ break; ++ ++ if (ch < INDEX_MINCHAR || ch >= INDEX_MAXCHAR) ++ bb_error_msg_and_die("bad module name"); ++ ++ ch -= INDEX_MINCHAR; ++ if (!cur->children[ch]) { ++ n = xzalloc(sizeof(index_node)); ++ cur->children[ch] = n; ++ n->prefix = xstrdup(&key[i+1]); ++ cur = n; ++ break; ++ } ++ ++ /* Descend into child node and continue */ ++ cur = cur->children[ch]; ++ i++; ++ } ++ ++ llist_add_to(&cur->values, value); ++ } ++} ++ ++static uint32_t index_write_node(FILE *out, index_node *n, void (*freeit)(void *data)) ++{ ++ uint32_t child_offs[INDEX_MAXCHAR-INDEX_MINCHAR]; ++ uint32_t offset; ++ uint8_t first = 255, last = 0; ++ unsigned i; ++ ++ for (i = 0; i < INDEX_MAXCHAR-INDEX_MINCHAR; i++) { ++ child_offs[i] = 0; ++ if (!n->children[i]) ++ continue; ++ child_offs[i] = index_write_node(out, n->children[i], freeit); ++ if (first > INDEX_MAXCHAR) ++ first = i; ++ last = i; ++ } ++ ++ offset = ftell(out); ++ ++ if (n->prefix[0]) { ++ fputs(n->prefix, out); ++ fputc('\0', out); ++ offset |= INDEX_NODE_PREFIX; ++ } ++ ++ if (first < INDEX_MAXCHAR) { ++ fputc(first + INDEX_MINCHAR, out); ++ fputc(last + INDEX_MINCHAR, out); ++ fwrite(child_offs + first, sizeof(uint32_t), last - first + 1, out); ++ offset |= INDEX_NODE_CHILDS; ++ } ++ ++ if (n->values) { ++ const llist_t *v; ++ unsigned int cnt; ++ uint32_t u; ++ ++ n->values = llist_rev(n->values); ++ for (v = n->values, cnt = 0; v != NULL; v = v->link, cnt++); ++ u = htonl(cnt); ++ fwrite(&u, sizeof(u), 1, out); ++ for (v = n->values, cnt = 0; v != NULL; v = v->link, cnt++) { ++ u = htonl(cnt); ++ fwrite(&u, sizeof(u), 1, out); ++ fputs(v->data, out); ++ fputc('\0', out); ++ } ++ offset |= INDEX_NODE_VALUES; ++ } ++ ++ llist_free(n->values, freeit); ++ free(n->prefix); ++ free(n); ++ ++ return htonl(offset); ++} ++ ++static void index_dump(const char *filename, int deps_file) ++{ ++ if (ENABLE_FEATURE_MODUTILS_BIN) { ++ FILE *out; ++ uint32_t header[3] = { ++ htonl(INDEX_MAGIC), ++ htonl(INDEX_VERSION), ++ }; ++ ++ if (option_mask32 & OPT_n) ++ filename = "/dev/null"; ++ else ++ filename = xasprintf("tmp.%s.bin", filename); ++ ++ out = xfopen_for_write(filename); ++ fwrite(header, sizeof(uint32_t), 3, out); ++ header[2] = index_write_node(out, G.root_node, deps_file ? free : 0); ++ rewind(out); ++ G.root_node = NULL; ++ fwrite(header, sizeof(uint32_t), 3, out); ++ if (fclose(out)) { ++ remove(filename); ++ bb_error_msg_and_die(bb_msg_write_error); ++ } ++ /* .bin files are mmap'ed; not renaming it may crash ++ * long standing daemon using libkmod */ ++ rename_or_warn(filename, filename + 4); ++ } ++} ++ + int depmod_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; + int depmod_main(int argc UNUSED_PARAM, char **argv) + { +@@ -178,6 +348,8 @@ int depmod_main(int argc UNUSED_PARAM, char **argv) + unsigned i; + int tmp; + ++ INIT_G(); ++ + getopt32(argv, "aAb:eF:nruqC:", &moddir_base, NULL, NULL); + argv += optind; + +@@ -210,53 +382,60 @@ int depmod_main(int argc UNUSED_PARAM, char **argv) + } + + /* Generate dependency and alias files */ +- if (!(option_mask32 & OPT_n)) +- xfreopen_write(CONFIG_DEFAULT_DEPMOD_FILE, stdout); +- ++ index_init(CONFIG_DEFAULT_DEPMOD_FILE); + moddb_foreach_module(&modules, m, i) { +- printf("%s:", m->name); +- ++ char *buf = xasprintf("%s:", m->name); + order_dep_list(&modules, m, m->deps); ++ + while (m->dnext != m) { + dep = m->dnext; +- printf(" %s", dep->name); +- ++ buf = gather_options_str(buf, dep->name); + /* unlink current entry */ + dep->dnext->dprev = dep->dprev; + dep->dprev->dnext = dep->dnext; + dep->dnext = dep->dprev = dep; + } +- bb_putchar('\n'); ++ index_add(m->modname, buf, ""); + } +- +-#if ENABLE_FEATURE_MODUTILS_ALIAS +- if (!(option_mask32 & OPT_n)) +- xfreopen_write("modules.alias", stdout); +- moddb_foreach_module(&modules, m, i) { +- while (m->aliases) { +- /* +- * Last word used to be a basename +- * (filename with path and .ko.* stripped) +- * at the time of module-init-tools 3.4. +- * kmod v.12 uses module name, i.e., s/-/_/g. +- */ +- printf("alias %s %s\n", +- (char*)llist_pop(&m->aliases), +- m->modname); ++ index_dump(CONFIG_DEFAULT_DEPMOD_FILE, 1); ++ ++ if (ENABLE_FEATURE_MODUTILS_ALIAS) { ++ index_init("modules.alias"); ++ moddb_foreach_module(&modules, m, i) { ++ while (m->aliases) { ++ /* ++ * Last word used to be a basename ++ * (filename with path and .ko.* stripped) ++ * at the time of module-init-tools 3.4. ++ * kmod v.12 uses module name, i.e., s/-/_/g. ++ */ ++ index_add((char*)llist_pop(&m->aliases), m->modname, "alias "); ++ } + } ++ index_dump("modules.alias", 0); + } +-#endif +-#if ENABLE_FEATURE_MODUTILS_SYMBOLS +- if (!(option_mask32 & OPT_n)) +- xfreopen_write("modules.symbols", stdout); +- moddb_foreach_module(&modules, m, i) { +- while (m->symbols) { +- printf("alias symbol:%s %s\n", +- (char*)llist_pop(&m->symbols), +- m->modname); ++ if (ENABLE_FEATURE_MODUTILS_SYMBOLS) { ++ index_init("modules.symbols"); ++ moddb_foreach_module(&modules, m, i) { ++ while (m->symbols) { ++ index_add((char*)llist_pop(&m->symbols), m->modname, "alias "); ++ } ++ } ++ index_dump("modules.symbols", 0); ++ } ++ if (ENABLE_FEATURE_MODUTILS_BIN) { ++ char line[PATH_MAX], modname[MODULE_NAME_LEN]; ++ FILE *in; ++ ++ index_init(NULL); ++ in = xfopen_for_read("modules.builtin"); ++ while (fgets(line, sizeof(line), in) != NULL) { ++ filename2modname(line, modname); ++ index_add(modname, (char *) "", 0); + } ++ fclose(in); ++ index_dump("modules.builtin", 0); + } +-#endif + + if (ENABLE_FEATURE_CLEAN_UP) + moddb_free(&modules); +diff --git a/modutils/modprobe.c b/modutils/modprobe.c +index 59f6d54f3..0a398a60f 100644 +--- a/modutils/modprobe.c ++++ b/modutils/modprobe.c +@@ -192,21 +192,6 @@ struct globals { + + static int read_config(const char *path); + +-static char *gather_options_str(char *opts, const char *append) +-{ +- /* Speed-optimized. We call gather_options_str many times. */ +- if (append) { +- if (opts == NULL) { +- opts = xstrdup(append); +- } else { +- int optlen = strlen(opts); +- opts = xrealloc(opts, optlen + strlen(append) + 2); +- sprintf(opts + optlen, " %s", append); +- } +- } +- return opts; +-} +- + static struct module_entry *get_or_add_modentry(const char *module) + { + return moddb_get_or_create(&G.db, module); +diff --git a/modutils/modutils.c b/modutils/modutils.c +index 6f7cd9721..257089af4 100644 +--- a/modutils/modutils.c ++++ b/modutils/modutils.c +@@ -66,6 +66,21 @@ void FAST_FUNC moddb_free(module_db *db) + } + } + ++char * FAST_FUNC gather_options_str(char *opts, const char *append) ++{ ++ /* Speed-optimized. We call gather_options_str many times. */ ++ if (append) { ++ if (opts == NULL) { ++ opts = xstrdup(append); ++ } else { ++ int optlen = strlen(opts); ++ opts = xrealloc(opts, optlen + strlen(append) + 2); ++ sprintf(opts + optlen, " %s", append); ++ } ++ } ++ return opts; ++} ++ + void FAST_FUNC replace(char *s, char what, char with) + { + while (*s) { +@@ -75,6 +90,22 @@ void FAST_FUNC replace(char *s, char what, char with) + } + } + ++char* FAST_FUNC replace_underscores(char *s) ++{ ++ int i; ++ for (i = 0; s[i]; i++) { ++ switch (s[i]) { ++ case '-': ++ s[i] = '_'; ++ break; ++ case '[': ++ i += strcspn(&s[i], "]"); ++ break; ++ } ++ } ++ return s; ++} ++ + int FAST_FUNC string_to_llist(char *string, llist_t **llist, const char *delim) + { + char *tok; +diff --git a/modutils/modutils.h b/modutils/modutils.h +index 4a702e97c..73e816028 100644 +--- a/modutils/modutils.h ++++ b/modutils/modutils.h +@@ -18,6 +18,20 @@ PUSH_AND_SET_FUNCTION_VISIBILITY_TO_HIDDEN + #define MODULE_NAME_LEN 256 + #define MODULE_HASH_SIZE 256 + ++/* .bin index format definitions */ ++#define INDEX_MAGIC 0xB007F457 ++#define INDEX_VERSION_MAJOR 0x0002 ++#define INDEX_VERSION_MINOR 0x0001 ++#define INDEX_VERSION ((INDEX_VERSION_MAJOR<<16)|INDEX_VERSION_MINOR) ++ ++enum node_offset { ++ INDEX_NODE_FLAGS = 0xF0000000, /* Flags in high nibble */ ++ INDEX_NODE_PREFIX = 0x80000000, ++ INDEX_NODE_VALUES = 0x40000000, ++ INDEX_NODE_CHILDS = 0x20000000, ++ INDEX_NODE_MASK = 0x0FFFFFFF, /* Offset value */ ++}; ++ + typedef struct module_entry { + struct module_entry *next; + char *name, *modname; +@@ -47,7 +61,9 @@ module_entry *moddb_get(module_db *db, const char *s) FAST_FUNC; + module_entry *moddb_get_or_create(module_db *db, const char *s) FAST_FUNC; + void moddb_free(module_db *db) FAST_FUNC; + ++char *gather_options_str(char *opts, const char *append) FAST_FUNC; + void replace(char *s, char what, char with) FAST_FUNC; ++char *replace_underscores(char *s) FAST_FUNC; + int string_to_llist(char *string, llist_t **llist, const char *delim) FAST_FUNC; + char *filename2modname(const char *filename, char *modname) FAST_FUNC; + #if ENABLE_FEATURE_CMDLINE_MODULE_OPTIONS +-- +2.16.2 + diff --git a/legacy/busybox/0009-sysklogd-add-Z-option-to-adjust-message-timezones.patch b/legacy/busybox/0009-sysklogd-add-Z-option-to-adjust-message-timezones.patch new file mode 100644 index 000000000..2624675c4 --- /dev/null +++ b/legacy/busybox/0009-sysklogd-add-Z-option-to-adjust-message-timezones.patch @@ -0,0 +1,104 @@ +From 1cb2e911c47f1b798ee610deabbea21ba6fb6961 Mon Sep 17 00:00:00 2001 +From: Shiz <hi@shiz.me> +Date: Mon, 8 May 2017 23:09:13 +0200 +Subject: [PATCH 09/11] sysklogd: add -Z option to adjust message timezones + +Some syslog() implementations like musl's[1] always send timestamps in UTC. +This change adds a new option to syslogd, -Z, to assume incoming timestamps +are always UTC and adjust them to the local timezone (of the syslogd) before +logging. + +[1]: http://www.openwall.com/lists/musl/2014/01/29/1 + +Signed-off-by: Shiz <hi@shiz.me> +--- + sysklogd/syslogd.c | 23 +++++++++++++++++++---- + 1 file changed, 19 insertions(+), 4 deletions(-) + +diff --git a/sysklogd/syslogd.c b/sysklogd/syslogd.c +index d64ff278f..159336ed7 100644 +--- a/sysklogd/syslogd.c ++++ b/sysklogd/syslogd.c +@@ -122,6 +122,7 @@ + //usage: "(this version of syslogd ignores /etc/syslog.conf)\n" + //usage: ) + //usage: "\n -n Run in foreground" ++//usage: "\n -Z Adjust incoming UTC times to local time" + //usage: IF_FEATURE_REMOTE_LOG( + //usage: "\n -R HOST[:PORT] Log to HOST:PORT (default PORT:514)" + //usage: "\n -L Log locally and via network (default is network only if -R)" +@@ -233,6 +234,8 @@ typedef struct logRule_t { + /*int markInterval;*/ \ + /* level of messages to be logged */ \ + int logLevel; \ ++ /* whether to adjust message timezone */\ ++ int adjustTimezone; \ + IF_FEATURE_ROTATE_LOGFILE( \ + /* max size of file before rotation */ \ + unsigned logFileSize; \ +@@ -316,6 +319,7 @@ enum { + OPTBIT_outfile, // -O + OPTBIT_loglevel, // -l + OPTBIT_small, // -S ++ OPTBIT_adjusttz, // -Z + IF_FEATURE_ROTATE_LOGFILE(OPTBIT_filesize ,) // -s + IF_FEATURE_ROTATE_LOGFILE(OPTBIT_rotatecnt ,) // -b + IF_FEATURE_REMOTE_LOG( OPTBIT_remotelog ,) // -R +@@ -330,6 +334,7 @@ enum { + OPT_outfile = 1 << OPTBIT_outfile , + OPT_loglevel = 1 << OPTBIT_loglevel, + OPT_small = 1 << OPTBIT_small , ++ OPT_adjusttz = 1 << OPTBIT_adjusttz, + OPT_filesize = IF_FEATURE_ROTATE_LOGFILE((1 << OPTBIT_filesize )) + 0, + OPT_rotatecnt = IF_FEATURE_ROTATE_LOGFILE((1 << OPTBIT_rotatecnt )) + 0, + OPT_remotelog = IF_FEATURE_REMOTE_LOG( (1 << OPTBIT_remotelog )) + 0, +@@ -339,7 +344,7 @@ enum { + OPT_cfg = IF_FEATURE_SYSLOGD_CFG( (1 << OPTBIT_cfg )) + 0, + OPT_kmsg = IF_FEATURE_KMSG_SYSLOG( (1 << OPTBIT_kmsg )) + 0, + }; +-#define OPTION_STR "m:nO:l:S" \ ++#define OPTION_STR "m:nO:l:SZ" \ + IF_FEATURE_ROTATE_LOGFILE("s:" ) \ + IF_FEATURE_ROTATE_LOGFILE("b:" ) \ + IF_FEATURE_REMOTE_LOG( "R:*") \ +@@ -815,17 +820,23 @@ static void timestamp_and_log(int pri, char *msg, int len) + { + char *timestamp; + time_t now; ++ struct tm nowtm = { .tm_isdst = 0 }; + + /* Jan 18 00:11:22 msg... */ + /* 01234567890123456 */ + if (len < 16 || msg[3] != ' ' || msg[6] != ' ' + || msg[9] != ':' || msg[12] != ':' || msg[15] != ' ' + ) { +- time(&now); ++ now = time(NULL); + timestamp = ctime(&now) + 4; /* skip day of week */ + } else { +- now = 0; +- timestamp = msg; ++ if (G.adjustTimezone && strptime(msg, "%b %e %T", &nowtm)) { ++ now = mktime(&nowtm) - timezone; ++ timestamp = ctime(&now) + 4; /* skip day of week */ ++ } else { ++ now = 0; ++ timestamp = msg; ++ } + msg += 16; + } + timestamp[15] = '\0'; +@@ -1130,6 +1141,10 @@ int syslogd_main(int argc UNUSED_PARAM, char **argv) + if (opts & OPT_loglevel) // -l + G.logLevel = xatou_range(opt_l, 1, 8); + //if (opts & OPT_small) // -S ++ if (opts & OPT_adjusttz) { // -Z ++ G.adjustTimezone = 1; ++ tzset(); ++ } + #if ENABLE_FEATURE_ROTATE_LOGFILE + if (opts & OPT_filesize) // -s + G.logFileSize = xatou_range(opt_s, 0, INT_MAX/1024) * 1024; +-- +2.13.2 + diff --git a/legacy/busybox/0010-Add-flag-for-not-following-symlinks-when-recursing.patch b/legacy/busybox/0010-Add-flag-for-not-following-symlinks-when-recursing.patch new file mode 100644 index 000000000..a45c46d09 --- /dev/null +++ b/legacy/busybox/0010-Add-flag-for-not-following-symlinks-when-recursing.patch @@ -0,0 +1,59 @@ +From 1c8c2316f98c2e4894c4c1686f0aa7937fcc0a17 Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Fri, 25 Jul 2014 15:28:33 +0200 +Subject: [PATCH 10/16] Add flag for not following symlinks when recursing + +function old new delta +.rodata 7934 7967 +33 +diff_longopts 253 270 +17 +packed_usage 1704 1720 +16 +diff_main 1665 1662 -3 +------------------------------------------------------------------------------ +(add/remove: 0/0 grow/shrink: 3/1 up/down: 66/-3) Total: 63 bytes +--- + editors/diff.c | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +diff --git a/editors/diff.c b/editors/diff.c +index 1462a9b18..2c899578e 100644 +--- a/editors/diff.c ++++ b/editors/diff.c +@@ -113,6 +113,9 @@ + //usage: "\n -N Treat absent files as empty" + //usage: "\n -q Output only whether files differ" + //usage: "\n -r Recurse" ++//usage: IF_LONG_OPTS( ++//usage: "\n --no-dereference Don't follow symlinks" ++//usage: ) + //usage: "\n -S Start with FILE when comparing directories" + //usage: "\n -T Make tabs line up by prefixing a tab when necessary" + //usage: "\n -s Report when two files are the same" +@@ -154,6 +157,7 @@ enum { /* Commandline flags */ + FLAG_p, /* not implemented */ + FLAG_B, + FLAG_E, /* not implemented */ ++ FLAG_no_deref, + }; + #define FLAG(x) (1 << FLAG_##x) + +@@ -867,7 +871,8 @@ static void diffdir(char *p[2], const char *s_start) + * Using list.len to specify its length, + * add_to_dirlist will remove it. */ + list[i].len = strlen(p[i]); +- recursive_action(p[i], ACTION_RECURSE | ACTION_FOLLOWLINKS, ++ recursive_action(p[i], ACTION_RECURSE | ++ ((option_mask32 & FLAG(no_deref)) ? 0 : ACTION_FOLLOWLINKS), + add_to_dirlist, skip_dir, &list[i], 0); + /* Sort dl alphabetically. + * GNU diff does this ignoring any number of trailing dots. +@@ -964,6 +969,7 @@ static const char diff_longopts[] ALIGN1 = + "report-identical-files\0" No_argument "s" + "starting-file\0" Required_argument "S" + "minimal\0" No_argument "d" ++ "no-dereference\0" No_argument "\xff" + ; + # define GETOPT32 getopt32long + # define LONGOPTS ,diff_longopts +-- +2.16.2 + diff --git a/legacy/busybox/0010-udhcpc-Don-t-background-if-n-is-given.patch b/legacy/busybox/0010-udhcpc-Don-t-background-if-n-is-given.patch new file mode 100644 index 000000000..75fe62dfd --- /dev/null +++ b/legacy/busybox/0010-udhcpc-Don-t-background-if-n-is-given.patch @@ -0,0 +1,45 @@ +From a663349a9ae6d62bfad1243a8781fb254065b480 Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Thu, 6 Jul 2017 13:39:15 +0200 +Subject: [PATCH 10/11] udhcpc: Don't background if -n is given + +we need add -b to our udhcpc options to prevent boot forever if there are no +dhcp server. We also need a way for users to disable this behavior by making +it possible to set -n option at runtime. +--- + networking/udhcp/dhcpc.c | 12 ++++++------ + 1 file changed, 6 insertions(+), 6 deletions(-) + +diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c +index 43aac1b85..bf53dd559 100644 +--- a/networking/udhcp/dhcpc.c ++++ b/networking/udhcp/dhcpc.c +@@ -1504,19 +1504,19 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv) + } + leasefail: + udhcp_run_script(NULL, "leasefail"); ++ if (opt & OPT_n) { /* abort if no lease */ ++ bb_error_msg("no lease, failing"); ++ retval = 1; ++ goto ret; ++ } + #if BB_MMU /* -b is not supported on NOMMU */ + if (opt & OPT_b) { /* background if no lease */ + bb_error_msg("no lease, forking to background"); + client_background(); + /* do not background again! */ + opt = ((opt & ~OPT_b) | OPT_f); +- } else +-#endif +- if (opt & OPT_n) { /* abort if no lease */ +- bb_error_msg("no lease, failing"); +- retval = 1; +- goto ret; + } ++#endif + /* wait before trying again */ + timeout = tryagain_timeout; + packet_num = 0; +-- +2.13.2 + diff --git a/legacy/busybox/0011-sysklogd-add-Z-option-to-adjust-message-timezones.patch b/legacy/busybox/0011-sysklogd-add-Z-option-to-adjust-message-timezones.patch new file mode 100644 index 000000000..b4ba240c4 --- /dev/null +++ b/legacy/busybox/0011-sysklogd-add-Z-option-to-adjust-message-timezones.patch @@ -0,0 +1,104 @@ +From 889a08dc0ae0d6b76692e6ed811f431c5b5db53c Mon Sep 17 00:00:00 2001 +From: Shiz <hi@shiz.me> +Date: Mon, 8 May 2017 23:09:13 +0200 +Subject: [PATCH 11/16] sysklogd: add -Z option to adjust message timezones + +Some syslog() implementations like musl's[1] always send timestamps in UTC. +This change adds a new option to syslogd, -Z, to assume incoming timestamps +are always UTC and adjust them to the local timezone (of the syslogd) before +logging. + +[1]: http://www.openwall.com/lists/musl/2014/01/29/1 + +Signed-off-by: Shiz <hi@shiz.me> +--- + sysklogd/syslogd.c | 23 +++++++++++++++++++---- + 1 file changed, 19 insertions(+), 4 deletions(-) + +diff --git a/sysklogd/syslogd.c b/sysklogd/syslogd.c +index 4265f4f90..eca955891 100644 +--- a/sysklogd/syslogd.c ++++ b/sysklogd/syslogd.c +@@ -122,6 +122,7 @@ + //usage: "(this version of syslogd ignores /etc/syslog.conf)\n" + //usage: ) + //usage: "\n -n Run in foreground" ++//usage: "\n -Z Adjust incoming UTC times to local time" + //usage: IF_FEATURE_REMOTE_LOG( + //usage: "\n -R HOST[:PORT] Log to HOST:PORT (default PORT:514)" + //usage: "\n -L Log locally and via network (default is network only if -R)" +@@ -233,6 +234,8 @@ typedef struct logRule_t { + /*int markInterval;*/ \ + /* level of messages to be logged */ \ + int logLevel; \ ++ /* whether to adjust message timezone */\ ++ int adjustTimezone; \ + IF_FEATURE_ROTATE_LOGFILE( \ + /* max size of file before rotation */ \ + unsigned logFileSize; \ +@@ -316,6 +319,7 @@ enum { + OPTBIT_outfile, // -O + OPTBIT_loglevel, // -l + OPTBIT_small, // -S ++ OPTBIT_adjusttz, // -Z + IF_FEATURE_ROTATE_LOGFILE(OPTBIT_filesize ,) // -s + IF_FEATURE_ROTATE_LOGFILE(OPTBIT_rotatecnt ,) // -b + IF_FEATURE_REMOTE_LOG( OPTBIT_remotelog ,) // -R +@@ -330,6 +334,7 @@ enum { + OPT_outfile = 1 << OPTBIT_outfile , + OPT_loglevel = 1 << OPTBIT_loglevel, + OPT_small = 1 << OPTBIT_small , ++ OPT_adjusttz = 1 << OPTBIT_adjusttz, + OPT_filesize = IF_FEATURE_ROTATE_LOGFILE((1 << OPTBIT_filesize )) + 0, + OPT_rotatecnt = IF_FEATURE_ROTATE_LOGFILE((1 << OPTBIT_rotatecnt )) + 0, + OPT_remotelog = IF_FEATURE_REMOTE_LOG( (1 << OPTBIT_remotelog )) + 0, +@@ -339,7 +344,7 @@ enum { + OPT_cfg = IF_FEATURE_SYSLOGD_CFG( (1 << OPTBIT_cfg )) + 0, + OPT_kmsg = IF_FEATURE_KMSG_SYSLOG( (1 << OPTBIT_kmsg )) + 0, + }; +-#define OPTION_STR "m:nO:l:S" \ ++#define OPTION_STR "m:nO:l:SZ" \ + IF_FEATURE_ROTATE_LOGFILE("s:" ) \ + IF_FEATURE_ROTATE_LOGFILE("b:" ) \ + IF_FEATURE_REMOTE_LOG( "R:*") \ +@@ -815,17 +820,23 @@ static void timestamp_and_log(int pri, char *msg, int len) + { + char *timestamp; + time_t now; ++ struct tm nowtm = { .tm_isdst = 0 }; + + /* Jan 18 00:11:22 msg... */ + /* 01234567890123456 */ + if (len < 16 || msg[3] != ' ' || msg[6] != ' ' + || msg[9] != ':' || msg[12] != ':' || msg[15] != ' ' + ) { +- time(&now); ++ now = time(NULL); + timestamp = ctime(&now) + 4; /* skip day of week */ + } else { +- now = 0; +- timestamp = msg; ++ if (G.adjustTimezone && strptime(msg, "%b %e %T", &nowtm)) { ++ now = mktime(&nowtm) - timezone; ++ timestamp = ctime(&now) + 4; /* skip day of week */ ++ } else { ++ now = 0; ++ timestamp = msg; ++ } + msg += 16; + } + timestamp[15] = '\0'; +@@ -1129,6 +1140,10 @@ int syslogd_main(int argc UNUSED_PARAM, char **argv) + if (opts & OPT_loglevel) // -l + G.logLevel = xatou_range(opt_l, 1, 8); + //if (opts & OPT_small) // -S ++ if (opts & OPT_adjusttz) { // -Z ++ G.adjustTimezone = 1; ++ tzset(); ++ } + #if ENABLE_FEATURE_ROTATE_LOGFILE + if (opts & OPT_filesize) // -s + G.logFileSize = xatou_range(opt_s, 0, INT_MAX/1024) * 1024; +-- +2.16.2 + diff --git a/legacy/busybox/0011-testsuite-fix-cpio-tests.patch b/legacy/busybox/0011-testsuite-fix-cpio-tests.patch new file mode 100644 index 000000000..a6eb803de --- /dev/null +++ b/legacy/busybox/0011-testsuite-fix-cpio-tests.patch @@ -0,0 +1,82 @@ +From 9a522cf388e321b47f9462bbbd7726323095f8db Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Thu, 6 Jul 2017 13:41:32 +0200 +Subject: [PATCH 11/11] testsuite: fix cpio tests + +The cpio tests don't search for the right output line correctly, +using a hardcoded tail offset. Instead, grep for the file entry +just added. + +The reverse-hunk patch tests seem to get the output order wrong, +and the tests pass when this is corrected. +--- + testsuite/cpio.tests | 6 +++--- + testsuite/patch.tests | 4 ++-- + 2 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/testsuite/cpio.tests b/testsuite/cpio.tests +index 88ec086b6..40f72c363 100755 +--- a/testsuite/cpio.tests ++++ b/testsuite/cpio.tests +@@ -129,7 +129,7 @@ SKIP= + + optional FEATURE_CPIO_O + testing "cpio uses by default uid/gid" \ +-"echo $0 | cpio -o -H newc | cpio -tv 2>&1 | tail -n +2 | awk ' { print \$2 } '; echo \$?" \ ++"echo $0 | cpio -o -H newc | cpio -tv 2>&1 | grep -F $(basename $0) | awk ' { print \$2 } '; echo \$?" \ + "\ + $user/$group + 0 +@@ -138,7 +138,7 @@ SKIP= + + optional FEATURE_CPIO_O + testing "cpio -R with create" \ +-"echo $0 | cpio -o -H newc -R 1234:5678 | cpio -tv 2>&1 | tail -n +2 | awk ' { print \$2 } '; echo \$?" \ ++"echo $0 | cpio -o -H newc -R 1234:5678 | cpio -tv 2>&1 | grep -F $(basename $0) | awk ' { print \$2 } '; echo \$?" \ + "\ + 1234/5678 + 0 +@@ -147,7 +147,7 @@ SKIP= + + optional FEATURE_CPIO_O + testing "cpio -R with extract" \ +-"echo $0 | cpio -o -H newc | cpio -tv -R 8765:4321 2>&1 | tail -n +2 | awk ' { print \$2 } '; echo \$?" \ ++"echo $0 | cpio -o -H newc | cpio -tv -R 8765:4321 2>&1 | grep -F $(basename $0) | awk ' { print \$2 } '; echo \$?" \ + "\ + 8765/4321 + 0 +diff --git a/testsuite/patch.tests b/testsuite/patch.tests +index 39205242c..1d48e90be 100755 +--- a/testsuite/patch.tests ++++ b/testsuite/patch.tests +@@ -75,12 +75,12 @@ zxc + testing "patch detects already applied hunk" \ + 'patch 2>&1; echo $?; cat input' \ + "\ ++patching file input + Possibly reversed hunk 1 at 4 + Hunk 1 FAILED 1/1. + abc + +def + 123 +-patching file input + 1 + abc + def +@@ -103,12 +103,12 @@ def + testing "patch detects already applied hunk at the EOF" \ + 'patch 2>&1; echo $?; cat input' \ + "\ ++patching file input + Possibly reversed hunk 1 at 4 + Hunk 1 FAILED 1/1. + abc + 123 + +456 +-patching file input + 1 + abc + 123 +-- +2.13.2 + diff --git a/legacy/busybox/0012-microcom-segfault.patch b/legacy/busybox/0012-microcom-segfault.patch new file mode 100644 index 000000000..4789079b3 --- /dev/null +++ b/legacy/busybox/0012-microcom-segfault.patch @@ -0,0 +1,31 @@ +From fd8a0116a29ea4014fac7fbdba2636fc7b51ffc2 Mon Sep 17 00:00:00 2001 +From: Marian Buschsieweke <marian.buschsieweke@ovgu.de> +Date: Wed, 2 Aug 2017 23:36:08 +0200 +Subject: [PATCH] miscutils/microcom: Fixed segfault + +microcom did not check if required parameter TTY is present. Thus, +bb_basename() was called with a NULL pointer if TTY was missing. +This commit adds the missing check. +--- + miscutils/microcom.c | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/miscutils/microcom.c b/miscutils/microcom.c +index 14b9f3baf..38f6425c1 100644 +--- a/miscutils/microcom.c ++++ b/miscutils/microcom.c +@@ -78,6 +78,11 @@ int microcom_main(int argc UNUSED_PARAM, char **argv) + // argc -= optind; + argv += optind; + ++ if (*argv == NULL){ ++ bb_show_usage(); ++ return EXIT_FAILURE; ++ } ++ + // try to create lock file in /var/lock + device_lock_file = (char *)bb_basename(argv[0]); + device_lock_file = xasprintf("/var/lock/LCK..%s", device_lock_file); +-- +2.13.3 + diff --git a/legacy/busybox/0012-udhcpc-Don-t-background-if-n-is-given.patch b/legacy/busybox/0012-udhcpc-Don-t-background-if-n-is-given.patch new file mode 100644 index 000000000..50719b003 --- /dev/null +++ b/legacy/busybox/0012-udhcpc-Don-t-background-if-n-is-given.patch @@ -0,0 +1,45 @@ +From 7f3d0620051c30e2047593092aa054565756b57f Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Thu, 6 Jul 2017 13:39:15 +0200 +Subject: [PATCH 12/16] udhcpc: Don't background if -n is given + +we need add -b to our udhcpc options to prevent boot forever if there are no +dhcp server. We also need a way for users to disable this behavior by making +it possible to set -n option at runtime. +--- + networking/udhcp/dhcpc.c | 12 ++++++------ + 1 file changed, 6 insertions(+), 6 deletions(-) + +diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c +index cc1d22c8e..10b846b0a 100644 +--- a/networking/udhcp/dhcpc.c ++++ b/networking/udhcp/dhcpc.c +@@ -1479,19 +1479,19 @@ int udhcpc_main(int argc UNUSED_PARAM, char **argv) + } + leasefail: + udhcp_run_script(NULL, "leasefail"); ++ if (opt & OPT_n) { /* abort if no lease */ ++ bb_error_msg("no lease, failing"); ++ retval = 1; ++ goto ret; ++ } + #if BB_MMU /* -b is not supported on NOMMU */ + if (opt & OPT_b) { /* background if no lease */ + bb_error_msg("no lease, forking to background"); + client_background(); + /* do not background again! */ + opt = ((opt & ~OPT_b) | OPT_f); +- } else +-#endif +- if (opt & OPT_n) { /* abort if no lease */ +- bb_error_msg("no lease, failing"); +- retval = 1; +- goto ret; + } ++#endif + /* wait before trying again */ + timeout = tryagain_timeout; + packet_num = 0; +-- +2.16.2 + diff --git a/legacy/busybox/0013-testsuite-fix-cpio-tests.patch b/legacy/busybox/0013-testsuite-fix-cpio-tests.patch new file mode 100644 index 000000000..a9ba0c4d0 --- /dev/null +++ b/legacy/busybox/0013-testsuite-fix-cpio-tests.patch @@ -0,0 +1,82 @@ +From 495a53387a12bffe393dcd0d6de2bc64374d38d2 Mon Sep 17 00:00:00 2001 +From: Natanael Copa <ncopa@alpinelinux.org> +Date: Thu, 6 Jul 2017 13:41:32 +0200 +Subject: [PATCH 13/16] testsuite: fix cpio tests + +The cpio tests don't search for the right output line correctly, +using a hardcoded tail offset. Instead, grep for the file entry +just added. + +The reverse-hunk patch tests seem to get the output order wrong, +and the tests pass when this is corrected. +--- + testsuite/cpio.tests | 6 +++--- + testsuite/patch.tests | 4 ++-- + 2 files changed, 5 insertions(+), 5 deletions(-) + +diff --git a/testsuite/cpio.tests b/testsuite/cpio.tests +index 88ec086b6..40f72c363 100755 +--- a/testsuite/cpio.tests ++++ b/testsuite/cpio.tests +@@ -129,7 +129,7 @@ SKIP= + + optional FEATURE_CPIO_O + testing "cpio uses by default uid/gid" \ +-"echo $0 | cpio -o -H newc | cpio -tv 2>&1 | tail -n +2 | awk ' { print \$2 } '; echo \$?" \ ++"echo $0 | cpio -o -H newc | cpio -tv 2>&1 | grep -F $(basename $0) | awk ' { print \$2 } '; echo \$?" \ + "\ + $user/$group + 0 +@@ -138,7 +138,7 @@ SKIP= + + optional FEATURE_CPIO_O + testing "cpio -R with create" \ +-"echo $0 | cpio -o -H newc -R 1234:5678 | cpio -tv 2>&1 | tail -n +2 | awk ' { print \$2 } '; echo \$?" \ ++"echo $0 | cpio -o -H newc -R 1234:5678 | cpio -tv 2>&1 | grep -F $(basename $0) | awk ' { print \$2 } '; echo \$?" \ + "\ + 1234/5678 + 0 +@@ -147,7 +147,7 @@ SKIP= + + optional FEATURE_CPIO_O + testing "cpio -R with extract" \ +-"echo $0 | cpio -o -H newc | cpio -tv -R 8765:4321 2>&1 | tail -n +2 | awk ' { print \$2 } '; echo \$?" \ ++"echo $0 | cpio -o -H newc | cpio -tv -R 8765:4321 2>&1 | grep -F $(basename $0) | awk ' { print \$2 } '; echo \$?" \ + "\ + 8765/4321 + 0 +diff --git a/testsuite/patch.tests b/testsuite/patch.tests +index 39205242c..1d48e90be 100755 +--- a/testsuite/patch.tests ++++ b/testsuite/patch.tests +@@ -75,12 +75,12 @@ zxc + testing "patch detects already applied hunk" \ + 'patch 2>&1; echo $?; cat input' \ + "\ ++patching file input + Possibly reversed hunk 1 at 4 + Hunk 1 FAILED 1/1. + abc + +def + 123 +-patching file input + 1 + abc + def +@@ -103,12 +103,12 @@ def + testing "patch detects already applied hunk at the EOF" \ + 'patch 2>&1; echo $?; cat input' \ + "\ ++patching file input + Possibly reversed hunk 1 at 4 + Hunk 1 FAILED 1/1. + abc + 123 + +456 +-patching file input + 1 + abc + 123 +-- +2.16.2 + diff --git a/legacy/busybox/0014-miscutils-microcom-Fixed-segfault.patch b/legacy/busybox/0014-miscutils-microcom-Fixed-segfault.patch new file mode 100644 index 000000000..59114460a --- /dev/null +++ b/legacy/busybox/0014-miscutils-microcom-Fixed-segfault.patch @@ -0,0 +1,31 @@ +From 2881266313824ed1c2d422ea905e25509f9bc924 Mon Sep 17 00:00:00 2001 +From: Marian Buschsieweke <marian.buschsieweke@ovgu.de> +Date: Wed, 2 Aug 2017 23:36:08 +0200 +Subject: [PATCH 14/16] miscutils/microcom: Fixed segfault + +microcom did not check if required parameter TTY is present. Thus, +bb_basename() was called with a NULL pointer if TTY was missing. +This commit adds the missing check. +--- + miscutils/microcom.c | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/miscutils/microcom.c b/miscutils/microcom.c +index fa090057e..96ea02b16 100644 +--- a/miscutils/microcom.c ++++ b/miscutils/microcom.c +@@ -76,6 +76,11 @@ int microcom_main(int argc UNUSED_PARAM, char **argv) + // argc -= optind; + argv += optind; + ++ if (*argv == NULL){ ++ bb_show_usage(); ++ return EXIT_FAILURE; ++ } ++ + // try to create lock file in /var/lock + device_lock_file = (char *)bb_basename(argv[0]); + device_lock_file = xasprintf("/var/lock/LCK..%s", device_lock_file); +-- +2.16.2 + diff --git a/legacy/busybox/0015-ash-introduce-a-config-option-to-search-current-dire.patch b/legacy/busybox/0015-ash-introduce-a-config-option-to-search-current-dire.patch new file mode 100644 index 000000000..9fc6f7e68 --- /dev/null +++ b/legacy/busybox/0015-ash-introduce-a-config-option-to-search-current-dire.patch @@ -0,0 +1,47 @@ +From 13c7e0cc7767b84e183ddbc3400171874478bf06 Mon Sep 17 00:00:00 2001 +From: Denys Vlasenko <vda.linux@googlemail.com> +Date: Fri, 26 Jan 2018 15:15:43 +0100 +Subject: [PATCH 15/16] ash: introduce a config option to search current + directory for sourced files + +--- + shell/ash.c | 13 ++++++++++++- + 1 file changed, 12 insertions(+), 1 deletion(-) + +diff --git a/shell/ash.c b/shell/ash.c +index d04096a9b..5dd184360 100644 +--- a/shell/ash.c ++++ b/shell/ash.c +@@ -132,6 +132,13 @@ + //config: you to run the specified command or builtin, + //config: even when there is a function with the same name. + //config: ++//config:config ASH_BASH_SOURCE_CURDIR ++//config: bool "'source' and '.' builtins search current directory after $PATH" ++//config: default n # do not encourage non-standard behavior ++//config: depends ASH_BASH_COMPAT ++//config: help ++//config: This is not compliant with standards. Avoid if possible. ++//config: + //config:config ASH_COMMAND_NOT_FOUND_HOOK + //config: bool "command_not_found_handle hook support" + //config: default y +@@ -12919,10 +12926,14 @@ find_dot_file(char *name) + if (fullname != name) + stunalloc(fullname); + } ++ /* not found in PATH */ + +- /* not found in the PATH */ ++#if ENABLE_ASH_BASH_SOURCE_CURDIR ++ return name; ++#else + ash_msg_and_raise_error("%s: not found", name); + /* NOTREACHED */ ++#endif + } + + static int FAST_FUNC +-- +2.16.2 + diff --git a/legacy/busybox/0016-top-handle-much-larger-VSZ-values.patch b/legacy/busybox/0016-top-handle-much-larger-VSZ-values.patch new file mode 100644 index 000000000..c8013403f --- /dev/null +++ b/legacy/busybox/0016-top-handle-much-larger-VSZ-values.patch @@ -0,0 +1,61 @@ +From 9d37e0e491d53e71c2e3ede1e002790e1026b9c6 Mon Sep 17 00:00:00 2001 +From: Denys Vlasenko <vda.linux@googlemail.com> +Date: Wed, 7 Mar 2018 03:59:52 +0100 +Subject: [PATCH 16/16] top: handle much larger VSZ values + +function old new delta +display_process_list 1018 999 -19 + +Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com> +--- + procps/top.c | 12 +++++------- + 1 file changed, 5 insertions(+), 7 deletions(-) + +diff --git a/procps/top.c b/procps/top.c +index b777c494e..9bb3eed29 100644 +--- a/procps/top.c ++++ b/procps/top.c +@@ -607,7 +607,6 @@ static NOINLINE void display_process_list(int lines_rem, int scr_width) + }; + + top_status_t *s; +- char vsz_str_buf[8]; + unsigned long total_memory = display_header(scr_width, &lines_rem); /* or use total_vsz? */ + /* xxx_shift and xxx_scale variables allow us to replace + * expensive divides with multiply and shift */ +@@ -688,19 +687,18 @@ static NOINLINE void display_process_list(int lines_rem, int scr_width) + lines_rem = ntop - G_scroll_ofs; + s = top + G_scroll_ofs; + while (--lines_rem >= 0) { ++ char vsz_str_buf[8]; + unsigned col; ++ + CALC_STAT(pmem, (s->vsz*pmem_scale + pmem_half) >> pmem_shift); + #if ENABLE_FEATURE_TOP_CPU_USAGE_PERCENTAGE + CALC_STAT(pcpu, (s->pcpu*pcpu_scale + pcpu_half) >> pcpu_shift); + #endif + +- if (s->vsz >= 100000) +- sprintf(vsz_str_buf, "%6ldm", s->vsz/1024); +- else +- sprintf(vsz_str_buf, "%7lu", s->vsz); ++ smart_ulltoa5(s->vsz, vsz_str_buf, " mgtpezy"); + /* PID PPID USER STAT VSZ %VSZ [%CPU] COMMAND */ + col = snprintf(line_buf, scr_width, +- "\n" "%5u%6u %-8.8s %s%s" FMT ++ "\n" "%5u%6u %-8.8s %s %.5s" FMT + IF_FEATURE_TOP_SMP_PROCESS(" %3d") + IF_FEATURE_TOP_CPU_USAGE_PERCENTAGE(FMT) + " ", +@@ -710,7 +708,7 @@ static NOINLINE void display_process_list(int lines_rem, int scr_width) + IF_FEATURE_TOP_SMP_PROCESS(, s->last_seen_on_cpu) + IF_FEATURE_TOP_CPU_USAGE_PERCENTAGE(, SHOW_STAT(pcpu)) + ); +- if ((int)(col + 1) < scr_width) ++ if ((int)(scr_width - col) > 1) + read_cmdline(line_buf + col, scr_width - col, s->pid, s->comm); + fputs(line_buf, stdout); + /* printf(" %d/%d %lld/%lld", s->pcpu, total_pcpu, +-- +2.16.2 + diff --git a/legacy/busybox/0017-ifupdown-do-not-fail-if-interface-disappears-during-.patch b/legacy/busybox/0017-ifupdown-do-not-fail-if-interface-disappears-during-.patch new file mode 100644 index 000000000..bdf24b783 --- /dev/null +++ b/legacy/busybox/0017-ifupdown-do-not-fail-if-interface-disappears-during-.patch @@ -0,0 +1,45 @@ +From 444a2f6be54186ae9ade1f2c3d4356cd62a720c5 Mon Sep 17 00:00:00 2001 +From: Kaarle Ritvanen <kaarle.ritvanen@datakunkku.fi> +Date: Fri, 23 Mar 2018 14:56:52 +0200 +Subject: [PATCH] ifupdown: do not fail if interface disappears during ifdown + +Interface may not exist because it got deleted by an ifdown hook script +earlier. This may happen when a virtual interface, such as VLAN, has multiple +iface blocks defined. + +Signed-off-by: Kaarle Ritvanen <kaarle.ritvanen@datakunkku.fi> +--- + networking/ifupdown.c | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/networking/ifupdown.c b/networking/ifupdown.c +index 534c9f0c7..35d13c5e1 100644 +--- a/networking/ifupdown.c ++++ b/networking/ifupdown.c +@@ -141,6 +141,7 @@ + #include "libbb.h" + #include "common_bufsiz.h" + /* After libbb.h, since it needs sys/types.h on some systems */ ++#include <net/if.h> + #include <sys/utsname.h> + #include <fnmatch.h> + +@@ -503,6 +504,7 @@ static int FAST_FUNC static_up6(struct interface_defn_t *ifd, execfn *exec) + + static int FAST_FUNC static_down6(struct interface_defn_t *ifd, execfn *exec) + { ++ if (!if_nametoindex(ifd->iface)) return 1; + # if ENABLE_FEATURE_IFUPDOWN_IP + return execute("ip link set %iface% down", ifd, exec); + # else +@@ -598,6 +600,7 @@ static int FAST_FUNC static_up(struct interface_defn_t *ifd, execfn *exec) + static int FAST_FUNC static_down(struct interface_defn_t *ifd, execfn *exec) + { + int result; ++ if (!if_nametoindex(ifd->iface)) return 2; + # if ENABLE_FEATURE_IFUPDOWN_IP + /* Optional "label LBL" is necessary if interface is an alias (eth0:0), + * otherwise "ip addr flush dev eth0:0" flushes all addresses on eth0. +-- +2.14.3 + diff --git a/legacy/busybox/APKBUILD b/legacy/busybox/APKBUILD new file mode 100644 index 000000000..44b3e352d --- /dev/null +++ b/legacy/busybox/APKBUILD @@ -0,0 +1,223 @@ +# Contributor: Łukasz Jendrysik <scadu@yandex.com> +# Contributor: Oliver Smith <ollieparanoid@bitmessage.ch> +# Maintainer: +pkgname=busybox +pkgver=1.28.4 +pkgrel=2 +pkgdesc="Size optimized toolbox of many common UNIX utilities" +url="https://busybox.net" +arch="all" +license="GPL-2.0-only AND GPL-2.0+" +makedepends_build="openssl-dev" +makedepends_host="linux-headers" +makedepends="$makedepends_build $makedepends_host" +checkdepends="zip" +provides="/sbin/init" +install="$pkgname.post-install $pkgname.post-upgrade $pkgname.pre-deinstall + $pkgname-extras.post-install $pkgname-extras.pre-deinstall" +subpackages="$pkgname-static $pkgname-suid $pkgname-extras $pkgname-binsh" +options="suid !check" +triggers="busybox.trigger=/bin:/usr/bin:/sbin:/usr/sbin:/lib/modules/*" +source="http://busybox.net/downloads/$pkgname-$pkgver.tar.bz2 + 0001-ash-add-support-for-command_not_found_handle-hook-fu.patch + 0002-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch + 0003-ash-exec-busybox.static.patch + 0004-app-location-for-cpio-vi-and-lspci.patch + 0005-udhcpc-set-default-discover-retries-to-5.patch + 0006-ping-make-ping-work-without-root-privileges.patch + 0007-fbsplash-support-console-switching.patch + 0008-fbsplash-support-image-and-bar-alignment-and-positio.patch + 0009-depmod-support-generating-kmod-binary-index-files.patch + 0010-Add-flag-for-not-following-symlinks-when-recursing.patch + 0011-sysklogd-add-Z-option-to-adjust-message-timezones.patch + 0012-udhcpc-Don-t-background-if-n-is-given.patch + 0013-testsuite-fix-cpio-tests.patch + 0014-miscutils-microcom-Fixed-segfault.patch + 0015-ash-introduce-a-config-option-to-search-current-dire.patch + 0016-top-handle-much-larger-VSZ-values.patch + 0017-ifupdown-do-not-fail-if-interface-disappears-during-.patch + + 0001-cat-fix-cat-e-and-cat-v-erroneously-numbering-1st-li.patch + + 0001-wget-emit-a-message-that-certificate-verification-is.patch + + acpid.logrotate + busyboxconfig + busyboxconfig-extras + bbsuid.c + dad.if-up + nologin.c + " + +# secfixes: +# 1.27.2-r4: +# - CVE-2017-16544 +# - CVE-2017-15873 +# - CVE-2017-15874 + +builddir="$srcdir"/$pkgname-$pkgver + +_staticdir="$srcdir"/build-static +_dyndir="$srcdir"/build-dynamic +_dyndir_extras="$srcdir"/build-dynamic-extras +_config="$srcdir"/busyboxconfig +_config_extras="$srcdir"/busyboxconfig-extras + +prepare() { + default_prepare + + cd "$builddir" + mkdir -p "$_staticdir" "$_dyndir" "$_dyndir_extras" + cp "$srcdir"/nologin.c loginutils/ +} + +build() { + # build bbsuid + msg "Building bbsuid" + ${CC:-${CROSS_COMPILE}gcc} ${CPPFLAGS} ${CFLAGS} \ + ${LDFLAGS} "$srcdir"/bbsuid.c -o "$_dyndir"/bbsuid + + # build dynamic + cd "$_dyndir" + msg "Building dynamic busybox" + cp "$_config" .config + [ "$CLIBC" = musl ] && sed -i \ + -e "s/CONFIG_EXTRA_COMPAT=y/CONFIG_EXTRA_COMPAT=n/" \ + .config + make -C "$builddir" O="$PWD" silentoldconfig + make + + # build dynamic (extras) + cd "$_dyndir_extras" + msg "Building dynamic busybox-extras" + cp "$_config_extras" .config + [ "$CLIBC" = musl ] && sed -i \ + -e "s/CONFIG_EXTRA_COMPAT=y/CONFIG_EXTRA_COMPAT=n/" \ + .config + make -C "$builddir" O="$PWD" silentoldconfig + make + + # build static + cd "$_staticdir" + msg "Building static busybox" + # enable internal ssl_client for static build + sed -e "s/.*CONFIG_PIE.*/\# CONFIG_PIE is not set/" \ + -e "s/.*CONFIG_STATIC.*/CONFIG_STATIC=y/" \ + -e "s/.*CONFIG_SSL_CLIENT.*/CONFIG_SSL_CLIENT=y/" \ + "$_config" > .config + # musl does not support GNU regex + [ "$CLIBC" = musl ] && sed -i \ + -e "s/CONFIG_EXTRA_COMPAT=y/CONFIG_EXTRA_COMPAT=n/" \ + .config + make -C "$builddir" O="$PWD" silentoldconfig + make + mv busybox busybox.static +} + +check() { + cd "$_dyndir" + SKIP_KNOWN_BUGS=1 make -C "$builddir" O="$PWD" V=1 check + + cd "$_dyndir_extras" + SKIP_KNOWN_BUGS=1 make -C "$builddir" O="$PWD" V=1 check +} + +package() { + cd "$_dyndir" + mkdir -p "$pkgdir"/usr/sbin "$pkgdir"/usr/bin "$pkgdir"/tmp \ + "$pkgdir"/var/cache/misc "$pkgdir"/bin "$pkgdir"/sbin + chmod 1777 "$pkgdir"/tmp + install -m755 busybox "$pkgdir"/bin/busybox || return 1 + # we need /bin/sh to be able to execute post-install + ln -s /bin/busybox "$pkgdir"/bin/sh + + #ifupdown needs those dirs to be present + mkdir -p \ + "$pkgdir"/etc/network/if-down.d \ + "$pkgdir"/etc/network/if-post-down.d \ + "$pkgdir"/etc/network/if-post-up.d \ + "$pkgdir"/etc/network/if-pre-down.d \ + "$pkgdir"/etc/network/if-pre-up.d \ + "$pkgdir"/etc/network/if-up.d + install -m775 "$srcdir"/dad.if-up "$pkgdir"/etc/network/if-up.d/dad + + install -Dm644 "$srcdir"/acpid.logrotate \ + "$pkgdir/etc/logrotate.d/acpid" + + mkdir -p "$pkgdir"/var/lib/udhcpd + install -Dm644 "$builddir"/examples/udhcp/udhcpd.conf \ + "$pkgdir"/etc/udhcpd.conf + cat >"$pkgdir"/etc/securetty <<EOF +console +tty1 +tty2 +tty3 +tty4 +tty5 +tty6 +tty7 +tty8 +tty9 +tty10 +tty11 +EOF +} + +extras() { + pkgdesc="Additional binaries of Busybox" + depends="${pkgname}" + install -Dm755 "$_dyndir_extras"/busybox "$subpkgdir"/bin/busybox-extras +} + +suid() { + pkgdesc="suid binaries of Busybox" + depends="${pkgname}" + + cd "$_dyndir" + mkdir -p "$subpkgdir"/bin + install -m4111 bbsuid "$subpkgdir"/bin/bbsuid +} + +static() { + pkgdesc="Statically linked Busybox" + mkdir -p "$subpkgdir"/bin + install -m755 "$_staticdir"/busybox.static \ + "$subpkgdir"/bin/busybox.static +} + +binsh() { + pkgdesc="Provide /bin/sh with BusyBox ash" + depends="${pkgname}" + provides="/bin/sh" + provider_priority=0 + + mkdir -p "$subpkgdir"/bin + mv "$pkgdir"/bin/sh "$subpkgdir"/bin +} + +sha512sums="92471617fcf3c1e28b468f3de2c83a1041f5ba5106580cc791e9c4cd602b7ccffabc51ce0807881ed734a89c3089113048265d6659a4d595528bd9150288d2ed busybox-1.28.4.tar.bz2 +51d4d58baff825a51d476bd4594cb8980ec2aa4d0c864a0eec39ccbbadd1ae9f1cd1b20f492a735ffcdf7c925573594f3c4363b0561c8aa7b91ef534bfc7b2e0 0001-ash-add-support-for-command_not_found_handle-hook-fu.patch +5d2fd3e521ee29d970f377363e3a3144eaf9f7714bc57494d743ded9e39c1ad93ea8759b2febd9c3786968b41e61b8d01ce2361aa997df177b644d63718470ba 0002-fsck-resolve-LABEL-.-UUID-.-spec-to-device.patch +cc5e5ce7a822ef51eb6b8065e1b802bc9d690857b8123cb4decf51b09c4ef655784401a68dd26e0a681fbb64bd2c0fed4001be6e33cac9049e516587ea53c17d 0003-ash-exec-busybox.static.patch +5f0611d21d1dc106d43ba23234babd41a2167d7032f3b09e825ae3dc9f9aaeb8d1882f59341daff99adecdfb8ba52a5c9fb423c8df3168b2e2304c5bd0ac4991 0004-app-location-for-cpio-vi-and-lspci.patch +bd4bb1f29f0287aa2ae4e43d791072802ba4f8863ea968612410a2819f7afaec5c0c731b4d91f360461ebfe26942f21e9ff69cbd5fb7d9800e62ef59fe954ab2 0005-udhcpc-set-default-discover-retries-to-5.patch +f03f852b97f3875d3051b225e6ffe52ed02ae8a8550287b3e09c2ef4d63914e1ab045ba5e2bc2dc2f3c8bf643485de4ebb36b97c74a8a6e49b6ba0261f2ddb94 0006-ping-make-ping-work-without-root-privileges.patch +a7b4ddb838f51e86040246e11a4b0df7bce37ed5159634bd2a8f388cf57be0551e6e63887b71b530a8a7b86dbdda6bbb3a090173f040050ea864b5f07674395d 0007-fbsplash-support-console-switching.patch +f8655833f71715629a4a93997939ca295cacb35f17843a36cb6fda285213bdbd258b2f84e321f81859491971412a520f697748ebd6fb46808f830f4ccfa77af4 0008-fbsplash-support-image-and-bar-alignment-and-positio.patch +f69031d048aa5e087cb6597ad2f7b39b520a5ef3713731e9090c5b65680cd7075bdf3a9443725fac49dce4345bc3345dc702b95d618d45a6d3be8682844784f4 0009-depmod-support-generating-kmod-binary-index-files.patch +b558f3ceb63e39545c3219796da64a7962bb53515a4eedea2bf9d81057774096b429145f0cd98da2542e3bdadaf92fb11d710fb1879768c9980bf58ccd104b6e 0010-Add-flag-for-not-following-symlinks-when-recursing.patch +f81d7966133d40a5d79cab4a4edf695bf7cc1f06cf2382c4ed99eea3a72cd222fe36c7b92e427262f67a81fcc2e7f6bff5986b32362c38da3c5163a49fd1ecab 0011-sysklogd-add-Z-option-to-adjust-message-timezones.patch +a96aa81d2f0104b5c28f02e80b3f77dbce77af93c174c09015a34850474d69e42c160fc8061c62f03465b6f793ead109dde7b0cc367d1e87694805d823f19d7e 0012-udhcpc-Don-t-background-if-n-is-given.patch +40c125a2ba19bcfaec46084bef98acb775a7f2521d854df41411afcfbc3025a1bdd029b0baf74550923db2541c23c1e9df5d5ded799d1d46dd7cf86a495e4c57 0013-testsuite-fix-cpio-tests.patch +4cbd38a3c2730ae38e34c5973bb63e40609c32f700d4943cc0e922394e8ee522d1512eb19c7885f5cee49834ab22b2594cb07164cacffefa39964a3b863f4e50 0014-miscutils-microcom-Fixed-segfault.patch +832eb44c52d2caad4bf6ea79fb17f10c116de3e90ed79038dabe3736d8e74507d1e0cb6f4f7689b4dd506b92437d8df7862038fc0213ecda259e40baf9d9b3de 0015-ash-introduce-a-config-option-to-search-current-dire.patch +185f11578dc3c3637f1acd1285c71b9e31f4244c57cd85b0848912c085a7a8c833d4c935ab1cadcb9852cf3185c7ffb08db8ea728fb19ab6e6fa90d89f13c75b 0016-top-handle-much-larger-VSZ-values.patch +d90d6b3406760fe3df6dbed46a0f4d1c02a69d5184ebc86d8c1692bc4576532127283ba3ff9a81e64f3660c279b8ee324dac7a426350873c45957067648651c6 0017-ifupdown-do-not-fail-if-interface-disappears-during-.patch +0dbe3ee424c0a6e4aba4f551f6b6b9ee087655a03747a40906961b141d40b1cbb2345438f17887a1b78d880cb3a7ad0116936dd7c05e95160febfd299423e83b 0001-cat-fix-cat-e-and-cat-v-erroneously-numbering-1st-li.patch +90f9e95f6f953df2cf579f701b3135bad910f514e94b3e23b953acec12b10f33aa9200169dc7b454c6a04fbd992a370e6ca835406f9b5495951e0a8416137000 0001-wget-emit-a-message-that-certificate-verification-is.patch +a9b1403c844c51934637215307dd9e2adb9458921047acff0d86dcf229b6e0027f4b2c6cdaa25a58407aad9d098fb5685d58eb5ff8d2aa3de4912cdea21fe54c acpid.logrotate +d65dc165488a179ab19482ad74e350df9dfdccf2363b26424d2d145e27ab0819cd0cfdfb79b4a2bd0bd7c6eda3b95ea61f3c264357986e78c4675df94d487aec busyboxconfig +0efbe22e2fd56993d92b6542d4ccffb2b42d50495be085c98f417a71f503b4071e2f092afcec77f78064d33ffb0922c28daa3cb9958e6d7fb26d5a660abd90f4 busyboxconfig-extras +0becc2186d6c32fb0c401cf7bc0e46268b38ce8892db33be1daf40273024c1c02d518283f44086a313a2ccef34230a1d945ec148cc173f26e6aa9d88a7426e54 bbsuid.c +a1127c8a384294135e11500fde7ead33b73d24b11c21911b08447a4c4ef71d7a9965d6466f60f2da64e3b877213b0a3e924a5add3c5333ee3ecde8c2a91c5e02 dad.if-up +061f7417c1cbf0424a5fab77e2f5912aa1593f39b33ea294af4c03518ca712d793a77ea82ff1f36e9cb98751d9faacb9d0240cdf0894efd8f26c13c28a692404 nologin.c" diff --git a/legacy/busybox/acpid.logrotate b/legacy/busybox/acpid.logrotate new file mode 100644 index 000000000..a37763540 --- /dev/null +++ b/legacy/busybox/acpid.logrotate @@ -0,0 +1,8 @@ +/var/log/acpid.log { + missingok + notifempty + sharedscripts + postrotate + /etc/init.d/acpid --ifstarted restart || true + endscript +} diff --git a/legacy/busybox/bbsuid.c b/legacy/busybox/bbsuid.c new file mode 100644 index 000000000..24d0d7d3e --- /dev/null +++ b/legacy/busybox/bbsuid.c @@ -0,0 +1,107 @@ +/* + * Copyright (C) 2008 Natanael Copa <natanael.copa@gmail.com> + * All rights reserved. + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License version 2 as published + * by the Free Software Foundation. See http://www.gnu.org/ for details. + * + */ + +#include <sys/stat.h> +#include <sys/types.h> + +#include <libgen.h> +#include <stdio.h> +#include <stdlib.h> +#include <string.h> +#include <unistd.h> +#include <err.h> + +#define BBSUID_PATH "/bin/bbsuid" + +const static char * applets[] = { + "/bin/mount", + "/bin/umount", + "/bin/su", + "/usr/bin/crontab", + "/usr/bin/passwd", + "/usr/bin/traceroute", + "/usr/bin/traceroute6", + "/usr/bin/vlock", + NULL +}; + + +static const char *applet_from_path(const char *str) +{ + const char *p = strrchr(str, '/'); + if (p == NULL) + p = str; + else + p++; + return p; +} + +static int is_valid_applet(const char *str) +{ + int i; + for (i = 0; applets[i] != NULL; i++) { + const char *a = applet_from_path(applets[i]); + if (strcmp(applet_from_path(str), a) == 0) + return 1; + } + return 0; +} + +int exec_busybox(const char *app, int argc, char **argv) +{ + char **newargv = malloc((argc + 2) * sizeof(char *)); + int i; + newargv[0] = "/bin/busybox"; + newargv[1] = (char *)app; + for (i = 1; i < argc; i++) + newargv[i+1] = argv[i]; + newargv[argc+1] = NULL; + execv(newargv[0], newargv); + perror(newargv[0]); + free(newargv); + return 1; +} + +static int install_links(void) +{ + int i, r = 0; + /* we don't want others than root to install the symlinks */ + if (getuid() != 0) + errx(1, "Only root can install symlinks"); + + for (i = 0; applets[i] != NULL; i++) { + const char *a = applets[i]; + struct stat st; + if (lstat(a, &st) == 0 && S_ISLNK(st.st_mode)) + unlink(a); + if (symlink(BBSUID_PATH, a) < 0) + r++; + } + + return r; +} + +int main(int argc, char **argv) +{ + const char *app = applet_from_path(argv[0]); + + if (strcmp(app, "bbsuid") == 0) { + if (argc == 2 && strcmp(argv[1], "--install") == 0) + return install_links(); + errx(1, "Use --install to install symlinks"); + } + + if (is_valid_applet(app)) + return exec_busybox(app, argc, argv); + + errx(1, "%s is not a valid applet", app); + return 1; +} + diff --git a/legacy/busybox/busybox-extras.post-install b/legacy/busybox/busybox-extras.post-install new file mode 100644 index 000000000..a0327a691 --- /dev/null +++ b/legacy/busybox/busybox-extras.post-install @@ -0,0 +1,4 @@ +#!/bin/sh + +# Create all symlinks +exec /bin/busybox-extras --install -s diff --git a/legacy/busybox/busybox-extras.pre-deinstall b/legacy/busybox/busybox-extras.pre-deinstall new file mode 100644 index 000000000..15461302c --- /dev/null +++ b/legacy/busybox/busybox-extras.pre-deinstall @@ -0,0 +1,9 @@ +#!/bin/sh + +# Remove all symlinks to busybox-extras +cd / +for link in $(busybox-extras --list --full); do + if [ -L "$link" ] && [ "$(readlink $link)" = "/bin/busybox-extras" ]; then + rm "$link" + fi +done diff --git a/legacy/busybox/busybox.post-install b/legacy/busybox/busybox.post-install new file mode 100644 index 000000000..a986b2f76 --- /dev/null +++ b/legacy/busybox/busybox.post-install @@ -0,0 +1,4 @@ +#!/bin/sh + +# We need the symlinks early +exec /bin/busybox --install -s diff --git a/legacy/busybox/busybox.post-upgrade b/legacy/busybox/busybox.post-upgrade new file mode 100644 index 000000000..291ed7a6d --- /dev/null +++ b/legacy/busybox/busybox.post-upgrade @@ -0,0 +1,26 @@ +#!/bin/sh + +# remove links that has been relocated +for link in /bin/install /bin/ip /bin/vi /usr/bin/lspci; do + if [ -L "$link" ] && [ "$(readlink $link)" = "/bin/busybox" ]; then + rm "$link" + fi +done +for link in /bin/ping /bin/ping6; do + if [ -L "$link" ] && [ "$(readlink $link)" = "/bin/bbsuid" ]; then + rm "$link" + fi +done + +# remove links of programs moved to busybox-extras +for link in /usr/bin/telnet /usr/sbin/httpd /usr/bin/ftpget /usr/bin/ftpput \ + /usr/sbin/ftpd /usr/bin/tftp /usr/sbin/fakeidentd /usr/sbin/dnsd \ + /usr/sbin/inetd /usr/sbin/udhcpd; do + if [ -L "$link" ] && [ "$(readlink $link)" = "/bin/busybox" ]; then + rm "$link" + echo "NOTE: $link has been moved to the package 'busybox-extras'" + fi +done + +# We need the symlinks early +exec /bin/busybox --install -s diff --git a/legacy/busybox/busybox.pre-deinstall b/legacy/busybox/busybox.pre-deinstall new file mode 100644 index 000000000..f1e10ba92 --- /dev/null +++ b/legacy/busybox/busybox.pre-deinstall @@ -0,0 +1,9 @@ +#!/bin/sh + +# Remove all symlinks to busybox +cd / +for link in $(busybox --list-full); do + if [ -L "$link" ] && [ "$(readlink $link)" = "/bin/busybox" ]; then + rm "$link" + fi +done diff --git a/legacy/busybox/busybox.trigger b/legacy/busybox/busybox.trigger new file mode 100644 index 000000000..e531a45b8 --- /dev/null +++ b/legacy/busybox/busybox.trigger @@ -0,0 +1,20 @@ +#!/bin/sh + +do_bb_install= + +for i in "$@"; do + case "$i" in + /lib/modules/*) + if [ -d "$i" ]; then + /bin/busybox depmod ${i#/lib/modules/} + fi + ;; + *) do_bb_install=yes;; + esac +done + +if [ -n "$do_bb_install" ]; then + [ -e /bin/bbsuid ] && /bin/bbsuid --install + [ -e /bin/busybox-extras ] && /bin/busybox-extras --install -s + /bin/busybox --install -s +fi diff --git a/legacy/busybox/busyboxconfig b/legacy/busybox/busyboxconfig new file mode 100644 index 000000000..d2ea6fd75 --- /dev/null +++ b/legacy/busybox/busyboxconfig @@ -0,0 +1,1155 @@ +# +# Automatically generated make config: don't edit +# Busybox version: 1.28.2 +# Wed Mar 28 12:24:02 2018 +# +CONFIG_HAVE_DOT_CONFIG=y + +# +# Settings +# +CONFIG_DESKTOP=y +# CONFIG_EXTRA_COMPAT is not set +# CONFIG_FEDORA_COMPAT is not set +# CONFIG_INCLUDE_SUSv2 is not set +CONFIG_LONG_OPTS=y +CONFIG_SHOW_USAGE=y +CONFIG_FEATURE_VERBOSE_USAGE=y +CONFIG_FEATURE_COMPRESS_USAGE=y +CONFIG_LFS=y +# CONFIG_PAM is not set +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_UTMP is not set +# CONFIG_FEATURE_WTMP is not set +CONFIG_FEATURE_PIDFILE=y +CONFIG_PID_FILE_PATH="/var/run" +CONFIG_BUSYBOX=y +CONFIG_FEATURE_INSTALLER=y +# CONFIG_INSTALL_NO_USR is not set +CONFIG_FEATURE_SUID=y +# CONFIG_FEATURE_SUID_CONFIG is not set +# CONFIG_FEATURE_SUID_CONFIG_QUIET is not set +# CONFIG_FEATURE_PREFER_APPLETS is not set +CONFIG_BUSYBOX_EXEC_PATH="/bin/busybox" +# CONFIG_SELINUX is not set +# CONFIG_FEATURE_CLEAN_UP is not set +CONFIG_FEATURE_SYSLOG=y +CONFIG_PLATFORM_LINUX=y + +# +# Build Options +# +# CONFIG_STATIC is not set +CONFIG_PIE=y +# CONFIG_NOMMU is not set +# CONFIG_BUILD_LIBBUSYBOX is not set +# CONFIG_FEATURE_LIBBUSYBOX_STATIC is not set +# CONFIG_FEATURE_INDIVIDUAL is not set +# CONFIG_FEATURE_SHARED_BUSYBOX is not set +CONFIG_CROSS_COMPILER_PREFIX="" +CONFIG_SYSROOT="" +CONFIG_EXTRA_CFLAGS="" +CONFIG_EXTRA_LDFLAGS="" +CONFIG_EXTRA_LDLIBS="" +# CONFIG_USE_PORTABLE_CODE is not set + +# +# Installation Options ("make install" behavior) +# +# CONFIG_INSTALL_APPLET_SYMLINKS is not set +# CONFIG_INSTALL_APPLET_HARDLINKS is not set +# CONFIG_INSTALL_APPLET_SCRIPT_WRAPPERS is not set +CONFIG_INSTALL_APPLET_DONT=y +# CONFIG_INSTALL_SH_APPLET_SYMLINK is not set +# CONFIG_INSTALL_SH_APPLET_HARDLINK is not set +# CONFIG_INSTALL_SH_APPLET_SCRIPT_WRAPPER is not set +CONFIG_PREFIX="/home/ncopa/aports/main/busybox/pkg/busybox" + +# +# Debugging Options +# +# CONFIG_DEBUG is not set +# CONFIG_DEBUG_PESSIMIZE is not set +# CONFIG_DEBUG_SANITIZE is not set +# CONFIG_UNIT_TEST is not set +# CONFIG_WERROR is not set +CONFIG_NO_DEBUG_LIB=y +# CONFIG_DMALLOC is not set +# CONFIG_EFENCE is not set + +# +# Library Tuning +# +# CONFIG_FEATURE_USE_BSS_TAIL is not set +CONFIG_FEATURE_RTMINMAX=y +CONFIG_FEATURE_BUFFERS_USE_MALLOC=y +# CONFIG_FEATURE_BUFFERS_GO_ON_STACK is not set +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +CONFIG_PASSWORD_MINLEN=6 +CONFIG_MD5_SMALL=0 +CONFIG_SHA3_SMALL=0 +CONFIG_FEATURE_FAST_TOP=y +# CONFIG_FEATURE_ETC_NETWORKS is not set +CONFIG_FEATURE_EDITING=y +CONFIG_FEATURE_EDITING_MAX_LEN=1024 +CONFIG_FEATURE_EDITING_VI=y +CONFIG_FEATURE_EDITING_HISTORY=8192 +CONFIG_FEATURE_EDITING_SAVEHISTORY=y +# CONFIG_FEATURE_EDITING_SAVE_ON_EXIT is not set +CONFIG_FEATURE_REVERSE_SEARCH=y +CONFIG_FEATURE_TAB_COMPLETION=y +CONFIG_FEATURE_USERNAME_COMPLETION=y +CONFIG_FEATURE_EDITING_FANCY_PROMPT=y +CONFIG_FEATURE_EDITING_ASK_TERMINAL=y +CONFIG_LOCALE_SUPPORT=y +CONFIG_UNICODE_SUPPORT=y +CONFIG_UNICODE_USING_LOCALE=y +# CONFIG_FEATURE_CHECK_UNICODE_IN_ENV is not set +CONFIG_SUBST_WCHAR=63 +CONFIG_LAST_SUPPORTED_WCHAR=1114111 +CONFIG_UNICODE_COMBINING_WCHARS=y +CONFIG_UNICODE_WIDE_WCHARS=y +# CONFIG_UNICODE_BIDI_SUPPORT is not set +# CONFIG_UNICODE_NEUTRAL_TABLE is not set +CONFIG_UNICODE_PRESERVE_BROKEN=y +CONFIG_FEATURE_NON_POSIX_CP=y +# CONFIG_FEATURE_VERBOSE_CP_MESSAGE is not set +CONFIG_FEATURE_USE_SENDFILE=y +CONFIG_FEATURE_COPYBUF_KB=16 +CONFIG_FEATURE_SKIP_ROOTFS=y +CONFIG_MONOTONIC_SYSCALL=y +# CONFIG_IOCTL_HEX2STR_ERROR is not set +CONFIG_FEATURE_HWIB=y + +# +# Applets +# + +# +# Archival Utilities +# +CONFIG_FEATURE_SEAMLESS_XZ=y +CONFIG_FEATURE_SEAMLESS_LZMA=y +CONFIG_FEATURE_SEAMLESS_BZ2=y +CONFIG_FEATURE_SEAMLESS_GZ=y +CONFIG_FEATURE_SEAMLESS_Z=y +# CONFIG_AR is not set +# CONFIG_FEATURE_AR_LONG_FILENAMES is not set +# CONFIG_FEATURE_AR_CREATE is not set +# CONFIG_UNCOMPRESS is not set +CONFIG_GUNZIP=y +CONFIG_ZCAT=y +CONFIG_FEATURE_GUNZIP_LONG_OPTIONS=y +CONFIG_BUNZIP2=y +CONFIG_BZCAT=y +CONFIG_UNLZMA=y +CONFIG_LZCAT=y +CONFIG_LZMA=y +CONFIG_UNXZ=y +CONFIG_XZCAT=y +# CONFIG_XZ is not set +CONFIG_BZIP2=y +CONFIG_FEATURE_BZIP2_DECOMPRESS=y +CONFIG_CPIO=y +CONFIG_FEATURE_CPIO_O=y +CONFIG_FEATURE_CPIO_P=y +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +CONFIG_GZIP=y +# CONFIG_FEATURE_GZIP_LONG_OPTIONS is not set +CONFIG_GZIP_FAST=2 +CONFIG_FEATURE_GZIP_LEVELS=y +CONFIG_FEATURE_GZIP_DECOMPRESS=y +CONFIG_LZOP=y +CONFIG_UNLZOP=y +CONFIG_LZOPCAT=y +# CONFIG_LZOP_COMPR_HIGH is not set +# CONFIG_RPM is not set +# CONFIG_RPM2CPIO is not set +CONFIG_TAR=y +CONFIG_FEATURE_TAR_LONG_OPTIONS=y +CONFIG_FEATURE_TAR_CREATE=y +CONFIG_FEATURE_TAR_AUTODETECT=y +CONFIG_FEATURE_TAR_FROM=y +CONFIG_FEATURE_TAR_OLDGNU_COMPATIBILITY=y +CONFIG_FEATURE_TAR_OLDSUN_COMPATIBILITY=y +CONFIG_FEATURE_TAR_GNU_EXTENSIONS=y +# CONFIG_FEATURE_TAR_TO_COMMAND is not set +CONFIG_FEATURE_TAR_UNAME_GNAME=y +CONFIG_FEATURE_TAR_NOPRESERVE_TIME=y +# CONFIG_FEATURE_TAR_SELINUX is not set +CONFIG_UNZIP=y +CONFIG_FEATURE_UNZIP_CDF=y +CONFIG_FEATURE_UNZIP_BZIP2=y +CONFIG_FEATURE_UNZIP_LZMA=y +CONFIG_FEATURE_UNZIP_XZ=y +CONFIG_FEATURE_LZMA_FAST=y + +# +# Coreutils +# +CONFIG_BASENAME=y +CONFIG_CAT=y +CONFIG_FEATURE_CATN=y +CONFIG_FEATURE_CATV=y +CONFIG_CHGRP=y +CONFIG_CHMOD=y +CONFIG_CHOWN=y +CONFIG_FEATURE_CHOWN_LONG_OPTIONS=y +CONFIG_CHROOT=y +CONFIG_CKSUM=y +CONFIG_COMM=y +CONFIG_CP=y +CONFIG_FEATURE_CP_LONG_OPTIONS=y +CONFIG_CUT=y +CONFIG_DATE=y +CONFIG_FEATURE_DATE_ISOFMT=y +# CONFIG_FEATURE_DATE_NANO is not set +CONFIG_FEATURE_DATE_COMPAT=y +CONFIG_DD=y +CONFIG_FEATURE_DD_SIGNAL_HANDLING=y +# CONFIG_FEATURE_DD_THIRD_STATUS_LINE is not set +CONFIG_FEATURE_DD_IBS_OBS=y +CONFIG_FEATURE_DD_STATUS=y +CONFIG_DF=y +CONFIG_FEATURE_DF_FANCY=y +CONFIG_DIRNAME=y +CONFIG_DOS2UNIX=y +CONFIG_UNIX2DOS=y +CONFIG_DU=y +CONFIG_FEATURE_DU_DEFAULT_BLOCKSIZE_1K=y +CONFIG_ECHO=y +CONFIG_FEATURE_FANCY_ECHO=y +CONFIG_ENV=y +CONFIG_EXPAND=y +CONFIG_UNEXPAND=y +CONFIG_EXPR=y +CONFIG_EXPR_MATH_SUPPORT_64=y +CONFIG_FACTOR=y +CONFIG_FALSE=y +CONFIG_FOLD=y +CONFIG_FSYNC=y +CONFIG_HEAD=y +CONFIG_FEATURE_FANCY_HEAD=y +CONFIG_HOSTID=y +CONFIG_ID=y +CONFIG_GROUPS=y +CONFIG_INSTALL=y +# CONFIG_FEATURE_INSTALL_LONG_OPTIONS is not set +CONFIG_LINK=y +CONFIG_LN=y +# CONFIG_LOGNAME is not set +CONFIG_LS=y +CONFIG_FEATURE_LS_FILETYPES=y +CONFIG_FEATURE_LS_FOLLOWLINKS=y +CONFIG_FEATURE_LS_RECURSIVE=y +CONFIG_FEATURE_LS_WIDTH=y +CONFIG_FEATURE_LS_SORTFILES=y +CONFIG_FEATURE_LS_TIMESTAMPS=y +CONFIG_FEATURE_LS_USERNAME=y +CONFIG_FEATURE_LS_COLOR=y +CONFIG_FEATURE_LS_COLOR_IS_DEFAULT=y +CONFIG_MD5SUM=y +CONFIG_SHA1SUM=y +CONFIG_SHA256SUM=y +CONFIG_SHA512SUM=y +CONFIG_SHA3SUM=y + +# +# Common options for md5sum, sha1sum, sha256sum, sha512sum, sha3sum +# +CONFIG_FEATURE_MD5_SHA1_SUM_CHECK=y +CONFIG_MKDIR=y +CONFIG_MKFIFO=y +CONFIG_MKNOD=y +CONFIG_MKTEMP=y +CONFIG_MV=y +CONFIG_NICE=y +CONFIG_NL=y +CONFIG_NOHUP=y +CONFIG_NPROC=y +CONFIG_OD=y +CONFIG_PASTE=y +CONFIG_PRINTENV=y +CONFIG_PRINTF=y +CONFIG_PWD=y +CONFIG_READLINK=y +CONFIG_FEATURE_READLINK_FOLLOW=y +CONFIG_REALPATH=y +CONFIG_RM=y +CONFIG_RMDIR=y +CONFIG_SEQ=y +CONFIG_SHRED=y +CONFIG_SHUF=y +CONFIG_SLEEP=y +CONFIG_FEATURE_FANCY_SLEEP=y +CONFIG_FEATURE_FLOAT_SLEEP=y +CONFIG_SORT=y +CONFIG_FEATURE_SORT_BIG=y +CONFIG_SPLIT=y +# CONFIG_FEATURE_SPLIT_FANCY is not set +CONFIG_STAT=y +CONFIG_FEATURE_STAT_FORMAT=y +CONFIG_FEATURE_STAT_FILESYSTEM=y +CONFIG_STTY=y +CONFIG_SUM=y +CONFIG_SYNC=y +CONFIG_FEATURE_SYNC_FANCY=y +CONFIG_TAC=y +CONFIG_TAIL=y +CONFIG_FEATURE_FANCY_TAIL=y +CONFIG_TEE=y +CONFIG_FEATURE_TEE_USE_BLOCK_IO=y +CONFIG_TEST=y +CONFIG_TEST1=y +CONFIG_TEST2=y +CONFIG_FEATURE_TEST_64=y +CONFIG_TIMEOUT=y +CONFIG_TOUCH=y +CONFIG_FEATURE_TOUCH_NODEREF=y +CONFIG_FEATURE_TOUCH_SUSV3=y +CONFIG_TR=y +CONFIG_FEATURE_TR_CLASSES=y +CONFIG_FEATURE_TR_EQUIV=y +CONFIG_TRUE=y +CONFIG_TRUNCATE=y +CONFIG_TTY=y +CONFIG_UNAME=y +CONFIG_UNAME_OSNAME="Linux" +CONFIG_BB_ARCH=y +CONFIG_UNIQ=y +CONFIG_UNLINK=y +CONFIG_USLEEP=y +CONFIG_UUDECODE=y +CONFIG_BASE64=y +CONFIG_UUENCODE=y +CONFIG_WC=y +# CONFIG_FEATURE_WC_LARGE is not set +# CONFIG_WHO is not set +# CONFIG_W is not set +# CONFIG_USERS is not set +CONFIG_WHOAMI=y +CONFIG_YES=y + +# +# Common options +# +CONFIG_FEATURE_VERBOSE=y + +# +# Common options for cp and mv +# +CONFIG_FEATURE_PRESERVE_HARDLINKS=y + +# +# Common options for df, du, ls +# +CONFIG_FEATURE_HUMAN_READABLE=y + +# +# Console Utilities +# +CONFIG_CHVT=y +CONFIG_CLEAR=y +CONFIG_DEALLOCVT=y +CONFIG_DUMPKMAP=y +# CONFIG_FGCONSOLE is not set +CONFIG_KBD_MODE=y +CONFIG_LOADFONT=y +CONFIG_SETFONT=y +CONFIG_FEATURE_SETFONT_TEXTUAL_MAP=y +CONFIG_DEFAULT_SETFONT_DIR="/usr/share" + +# +# Common options for loadfont and setfont +# +CONFIG_FEATURE_LOADFONT_PSF2=y +CONFIG_FEATURE_LOADFONT_RAW=y +CONFIG_LOADKMAP=y +CONFIG_OPENVT=y +CONFIG_RESET=y +CONFIG_RESIZE=y +CONFIG_FEATURE_RESIZE_PRINT=y +CONFIG_SETCONSOLE=y +# CONFIG_FEATURE_SETCONSOLE_LONG_OPTIONS is not set +CONFIG_SETKEYCODES=y +CONFIG_SETLOGCONS=y +CONFIG_SHOWKEY=y + +# +# Debian Utilities +# +CONFIG_PIPE_PROGRESS=y +CONFIG_RUN_PARTS=y +CONFIG_FEATURE_RUN_PARTS_LONG_OPTIONS=y +# CONFIG_FEATURE_RUN_PARTS_FANCY is not set +# CONFIG_START_STOP_DAEMON is not set +# CONFIG_FEATURE_START_STOP_DAEMON_LONG_OPTIONS is not set +# CONFIG_FEATURE_START_STOP_DAEMON_FANCY is not set +CONFIG_WHICH=y + +# +# klibc-utils +# +# CONFIG_MINIPS is not set +# CONFIG_NUKE is not set +# CONFIG_RESUME is not set +# CONFIG_RUN_INIT is not set + +# +# Editors +# +CONFIG_AWK=y +CONFIG_FEATURE_AWK_LIBM=y +CONFIG_FEATURE_AWK_GNU_EXTENSIONS=y +CONFIG_CMP=y +CONFIG_DIFF=y +CONFIG_FEATURE_DIFF_LONG_OPTIONS=y +CONFIG_FEATURE_DIFF_DIR=y +CONFIG_ED=y +CONFIG_PATCH=y +CONFIG_SED=y +CONFIG_VI=y +CONFIG_FEATURE_VI_MAX_LEN=1024 +CONFIG_FEATURE_VI_8BIT=y +CONFIG_FEATURE_VI_COLON=y +CONFIG_FEATURE_VI_YANKMARK=y +CONFIG_FEATURE_VI_SEARCH=y +# CONFIG_FEATURE_VI_REGEX_SEARCH is not set +CONFIG_FEATURE_VI_USE_SIGNALS=y +CONFIG_FEATURE_VI_DOT_CMD=y +CONFIG_FEATURE_VI_READONLY=y +CONFIG_FEATURE_VI_SETOPTS=y +CONFIG_FEATURE_VI_SET=y +CONFIG_FEATURE_VI_WIN_RESIZE=y +CONFIG_FEATURE_VI_ASK_TERMINAL=y +CONFIG_FEATURE_VI_UNDO=y +CONFIG_FEATURE_VI_UNDO_QUEUE=y +CONFIG_FEATURE_VI_UNDO_QUEUE_MAX=256 +CONFIG_FEATURE_ALLOW_EXEC=y + +# +# Finding Utilities +# +CONFIG_FIND=y +CONFIG_FEATURE_FIND_PRINT0=y +CONFIG_FEATURE_FIND_MTIME=y +CONFIG_FEATURE_FIND_MMIN=y +CONFIG_FEATURE_FIND_PERM=y +CONFIG_FEATURE_FIND_TYPE=y +CONFIG_FEATURE_FIND_XDEV=y +CONFIG_FEATURE_FIND_MAXDEPTH=y +CONFIG_FEATURE_FIND_NEWER=y +CONFIG_FEATURE_FIND_INUM=y +CONFIG_FEATURE_FIND_EXEC=y +CONFIG_FEATURE_FIND_EXEC_PLUS=y +CONFIG_FEATURE_FIND_USER=y +CONFIG_FEATURE_FIND_GROUP=y +CONFIG_FEATURE_FIND_NOT=y +CONFIG_FEATURE_FIND_DEPTH=y +CONFIG_FEATURE_FIND_PAREN=y +CONFIG_FEATURE_FIND_SIZE=y +CONFIG_FEATURE_FIND_PRUNE=y +CONFIG_FEATURE_FIND_DELETE=y +CONFIG_FEATURE_FIND_PATH=y +CONFIG_FEATURE_FIND_REGEX=y +# CONFIG_FEATURE_FIND_CONTEXT is not set +CONFIG_FEATURE_FIND_LINKS=y +CONFIG_GREP=y +CONFIG_EGREP=y +CONFIG_FGREP=y +CONFIG_FEATURE_GREP_CONTEXT=y +CONFIG_XARGS=y +CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION=y +CONFIG_FEATURE_XARGS_SUPPORT_QUOTES=y +CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT=y +CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM=y +CONFIG_FEATURE_XARGS_SUPPORT_REPL_STR=y +CONFIG_FEATURE_XARGS_SUPPORT_PARALLEL=y +CONFIG_FEATURE_XARGS_SUPPORT_ARGS_FILE=y + +# +# Init Utilities +# +# CONFIG_BOOTCHARTD is not set +# CONFIG_FEATURE_BOOTCHARTD_BLOATED_HEADER is not set +# CONFIG_FEATURE_BOOTCHARTD_CONFIG_FILE is not set +CONFIG_HALT=y +CONFIG_POWEROFF=y +CONFIG_REBOOT=y +# CONFIG_FEATURE_CALL_TELINIT is not set +CONFIG_TELINIT_PATH="" +CONFIG_INIT=y +# CONFIG_LINUXRC is not set +CONFIG_FEATURE_USE_INITTAB=y +CONFIG_FEATURE_KILL_REMOVED=y +CONFIG_FEATURE_KILL_DELAY=0 +CONFIG_FEATURE_INIT_SCTTY=y +CONFIG_FEATURE_INIT_SYSLOG=y +CONFIG_FEATURE_INIT_QUIET=y +# CONFIG_FEATURE_INIT_COREDUMPS is not set +CONFIG_INIT_TERMINAL_TYPE="linux" +# CONFIG_FEATURE_INIT_MODIFY_CMDLINE is not set + +# +# Login/Password Management Utilities +# +CONFIG_FEATURE_SHADOWPASSWDS=y +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_USE_BB_SHADOW is not set +# CONFIG_USE_BB_CRYPT is not set +# CONFIG_USE_BB_CRYPT_SHA is not set +CONFIG_ADD_SHELL=y +CONFIG_REMOVE_SHELL=y +CONFIG_ADDGROUP=y +CONFIG_FEATURE_ADDUSER_TO_GROUP=y +CONFIG_ADDUSER=y +CONFIG_FEATURE_CHECK_NAMES=y +CONFIG_LAST_ID=256000 +CONFIG_FIRST_SYSTEM_ID=100 +CONFIG_LAST_SYSTEM_ID=999 +CONFIG_CHPASSWD=y +CONFIG_FEATURE_DEFAULT_PASSWD_ALGO="sha512" +CONFIG_CRYPTPW=y +CONFIG_MKPASSWD=y +CONFIG_DELUSER=y +CONFIG_DELGROUP=y +CONFIG_FEATURE_DEL_USER_FROM_GROUP=y +CONFIG_GETTY=y +CONFIG_LOGIN=y +CONFIG_LOGIN_SESSION_AS_CHILD=y +CONFIG_LOGIN_SCRIPTS=y +CONFIG_FEATURE_NOLOGIN=y +CONFIG_FEATURE_SECURETTY=y +CONFIG_NOLOGIN=y +CONFIG_PASSWD=y +CONFIG_FEATURE_PASSWD_WEAK_CHECK=y +CONFIG_SU=y +CONFIG_FEATURE_SU_SYSLOG=y +CONFIG_FEATURE_SU_CHECKS_SHELLS=y +CONFIG_FEATURE_SU_BLANK_PW_NEEDS_SECURE_TTY=y +# CONFIG_SULOGIN is not set +CONFIG_VLOCK=y + +# +# Linux Ext2 FS Progs +# +# CONFIG_CHATTR is not set +CONFIG_FSCK=y +# CONFIG_LSATTR is not set +# CONFIG_TUNE2FS is not set + +# +# Linux Module Utilities +# +# CONFIG_MODPROBE_SMALL is not set +CONFIG_DEPMOD=y +CONFIG_INSMOD=y +CONFIG_LSMOD=y +CONFIG_FEATURE_LSMOD_PRETTY_2_6_OUTPUT=y +CONFIG_MODINFO=y +CONFIG_MODPROBE=y +CONFIG_FEATURE_MODPROBE_BLACKLIST=y +CONFIG_RMMOD=y + +# +# Options common to multiple modutils +# +CONFIG_FEATURE_CMDLINE_MODULE_OPTIONS=y +# CONFIG_FEATURE_MODPROBE_SMALL_CHECK_ALREADY_LOADED is not set +# CONFIG_FEATURE_2_4_MODULES is not set +# CONFIG_FEATURE_INSMOD_VERSION_CHECKING is not set +# CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS is not set +# CONFIG_FEATURE_INSMOD_LOADINKMEM is not set +# CONFIG_FEATURE_INSMOD_LOAD_MAP is not set +# CONFIG_FEATURE_INSMOD_LOAD_MAP_FULL is not set +CONFIG_FEATURE_CHECK_TAINTED_MODULE=y +# CONFIG_FEATURE_INSMOD_TRY_MMAP is not set +CONFIG_FEATURE_MODUTILS_ALIAS=y +CONFIG_FEATURE_MODUTILS_BIN=y +CONFIG_FEATURE_MODUTILS_SYMBOLS=y +CONFIG_DEFAULT_MODULES_DIR="/lib/modules" +CONFIG_DEFAULT_DEPMOD_FILE="modules.dep" + +# +# Linux System Utilities +# +CONFIG_ACPID=y +CONFIG_FEATURE_ACPID_COMPAT=y +CONFIG_BLKDISCARD=y +CONFIG_BLKID=y +CONFIG_FEATURE_BLKID_TYPE=y +CONFIG_BLOCKDEV=y +CONFIG_CAL=y +# CONFIG_CHRT is not set +CONFIG_DMESG=y +CONFIG_FEATURE_DMESG_PRETTY=y +CONFIG_EJECT=y +CONFIG_FEATURE_EJECT_SCSI=y +CONFIG_FALLOCATE=y +CONFIG_FATATTR=y +CONFIG_FBSET=y +CONFIG_FEATURE_FBSET_FANCY=y +CONFIG_FEATURE_FBSET_READMODE=y +CONFIG_FDFORMAT=y +CONFIG_FDISK=y +# CONFIG_FDISK_SUPPORT_LARGE_DISKS is not set +CONFIG_FEATURE_FDISK_WRITABLE=y +CONFIG_FEATURE_AIX_LABEL=y +CONFIG_FEATURE_SGI_LABEL=y +CONFIG_FEATURE_SUN_LABEL=y +CONFIG_FEATURE_OSF_LABEL=y +CONFIG_FEATURE_GPT_LABEL=y +CONFIG_FEATURE_FDISK_ADVANCED=y +CONFIG_FINDFS=y +CONFIG_FLOCK=y +CONFIG_FDFLUSH=y +# CONFIG_FREERAMDISK is not set +# CONFIG_FSCK_MINIX is not set +# CONFIG_FSFREEZE is not set +CONFIG_FSTRIM=y +CONFIG_GETOPT=y +CONFIG_FEATURE_GETOPT_LONG=y +CONFIG_HEXDUMP=y +CONFIG_FEATURE_HEXDUMP_REVERSE=y +CONFIG_HD=y +CONFIG_XXD=y +CONFIG_HWCLOCK=y +CONFIG_FEATURE_HWCLOCK_ADJTIME_FHS=y +CONFIG_IONICE=y +CONFIG_IPCRM=y +CONFIG_IPCS=y +# CONFIG_LAST is not set +# CONFIG_FEATURE_LAST_FANCY is not set +CONFIG_LOSETUP=y +CONFIG_LSPCI=y +CONFIG_LSUSB=y +CONFIG_MDEV=y +CONFIG_FEATURE_MDEV_CONF=y +CONFIG_FEATURE_MDEV_RENAME=y +CONFIG_FEATURE_MDEV_RENAME_REGEXP=y +CONFIG_FEATURE_MDEV_EXEC=y +CONFIG_FEATURE_MDEV_LOAD_FIRMWARE=y +CONFIG_MESG=y +CONFIG_FEATURE_MESG_ENABLE_ONLY_GROUP=y +# CONFIG_MKE2FS is not set +# CONFIG_MKFS_EXT2 is not set +# CONFIG_MKFS_MINIX is not set +# CONFIG_FEATURE_MINIX2 is not set +# CONFIG_MKFS_REISER is not set +CONFIG_MKDOSFS=y +CONFIG_MKFS_VFAT=y +CONFIG_MKSWAP=y +CONFIG_FEATURE_MKSWAP_UUID=y +CONFIG_MORE=y +CONFIG_MOUNT=y +CONFIG_FEATURE_MOUNT_FAKE=y +CONFIG_FEATURE_MOUNT_VERBOSE=y +CONFIG_FEATURE_MOUNT_HELPERS=y +CONFIG_FEATURE_MOUNT_LABEL=y +# CONFIG_FEATURE_MOUNT_NFS is not set +CONFIG_FEATURE_MOUNT_CIFS=y +CONFIG_FEATURE_MOUNT_FLAGS=y +CONFIG_FEATURE_MOUNT_FSTAB=y +# CONFIG_FEATURE_MOUNT_OTHERTAB is not set +CONFIG_MOUNTPOINT=y +CONFIG_NSENTER=y +# CONFIG_PIVOT_ROOT is not set +CONFIG_RDATE=y +CONFIG_RDEV=y +CONFIG_READPROFILE=y +CONFIG_RENICE=y +CONFIG_REV=y +# CONFIG_RTCWAKE is not set +# CONFIG_SCRIPT is not set +# CONFIG_SCRIPTREPLAY is not set +# CONFIG_SETARCH is not set +CONFIG_LINUX32=y +CONFIG_LINUX64=y +CONFIG_SETPRIV=y +CONFIG_FEATURE_SETPRIV_DUMP=y +CONFIG_FEATURE_SETPRIV_CAPABILITIES=y +CONFIG_FEATURE_SETPRIV_CAPABILITY_NAMES=y +CONFIG_SETSID=y +CONFIG_SWAPON=y +CONFIG_FEATURE_SWAPON_DISCARD=y +CONFIG_FEATURE_SWAPON_PRI=y +CONFIG_SWAPOFF=y +CONFIG_FEATURE_SWAPONOFF_LABEL=y +CONFIG_SWITCH_ROOT=y +# CONFIG_TASKSET is not set +# CONFIG_FEATURE_TASKSET_FANCY is not set +# CONFIG_UEVENT is not set +CONFIG_UMOUNT=y +CONFIG_FEATURE_UMOUNT_ALL=y +CONFIG_UNSHARE=y +# CONFIG_WALL is not set + +# +# Common options for mount/umount +# +CONFIG_FEATURE_MOUNT_LOOP=y +CONFIG_FEATURE_MOUNT_LOOP_CREATE=y +# CONFIG_FEATURE_MTAB_SUPPORT is not set +CONFIG_VOLUMEID=y + +# +# Filesystem/Volume identification +# +CONFIG_FEATURE_VOLUMEID_BCACHE=y +CONFIG_FEATURE_VOLUMEID_BTRFS=y +CONFIG_FEATURE_VOLUMEID_CRAMFS=y +CONFIG_FEATURE_VOLUMEID_EXFAT=y +CONFIG_FEATURE_VOLUMEID_EXT=y +CONFIG_FEATURE_VOLUMEID_F2FS=y +CONFIG_FEATURE_VOLUMEID_FAT=y +# CONFIG_FEATURE_VOLUMEID_HFS is not set +CONFIG_FEATURE_VOLUMEID_ISO9660=y +CONFIG_FEATURE_VOLUMEID_JFS=y +CONFIG_FEATURE_VOLUMEID_LINUXRAID=y +CONFIG_FEATURE_VOLUMEID_LINUXSWAP=y +CONFIG_FEATURE_VOLUMEID_LUKS=y +CONFIG_FEATURE_VOLUMEID_MINIX=y +CONFIG_FEATURE_VOLUMEID_NILFS=y +CONFIG_FEATURE_VOLUMEID_NTFS=y +CONFIG_FEATURE_VOLUMEID_OCFS2=y +CONFIG_FEATURE_VOLUMEID_REISERFS=y +# CONFIG_FEATURE_VOLUMEID_ROMFS is not set +CONFIG_FEATURE_VOLUMEID_SQUASHFS=y +# CONFIG_FEATURE_VOLUMEID_SYSV is not set +CONFIG_FEATURE_VOLUMEID_UBIFS=y +CONFIG_FEATURE_VOLUMEID_UDF=y +CONFIG_FEATURE_VOLUMEID_XFS=y + +# +# Miscellaneous Utilities +# +CONFIG_ADJTIMEX=y +CONFIG_BBCONFIG=y +CONFIG_FEATURE_COMPRESS_BBCONFIG=y +CONFIG_BEEP=y +CONFIG_FEATURE_BEEP_FREQ=440 +CONFIG_FEATURE_BEEP_LENGTH_MS=30 +# CONFIG_CHAT is not set +# CONFIG_FEATURE_CHAT_NOFAIL is not set +# CONFIG_FEATURE_CHAT_TTY_HIFI is not set +# CONFIG_FEATURE_CHAT_IMPLICIT_CR is not set +# CONFIG_FEATURE_CHAT_SWALLOW_OPTS is not set +# CONFIG_FEATURE_CHAT_SEND_ESCAPES is not set +# CONFIG_FEATURE_CHAT_VAR_ABORT_LEN is not set +# CONFIG_FEATURE_CHAT_CLR_ABORT is not set +CONFIG_CONSPY=y +CONFIG_CROND=y +CONFIG_FEATURE_CROND_D=y +CONFIG_FEATURE_CROND_CALL_SENDMAIL=y +CONFIG_FEATURE_CROND_SPECIAL_TIMES=y +CONFIG_FEATURE_CROND_DIR="/var/spool/cron" +CONFIG_CRONTAB=y +CONFIG_DC=y +CONFIG_FEATURE_DC_LIBM=y +# CONFIG_DEVFSD is not set +# CONFIG_DEVFSD_MODLOAD is not set +# CONFIG_DEVFSD_FG_NP is not set +# CONFIG_DEVFSD_VERBOSE is not set +# CONFIG_FEATURE_DEVFS is not set +# CONFIG_DEVMEM is not set +CONFIG_FBSPLASH=y +# CONFIG_FLASH_ERASEALL is not set +# CONFIG_FLASH_LOCK is not set +# CONFIG_FLASH_UNLOCK is not set +# CONFIG_FLASHCP is not set +CONFIG_HDPARM=y +# CONFIG_FEATURE_HDPARM_GET_IDENTITY is not set +# CONFIG_FEATURE_HDPARM_HDIO_SCAN_HWIF is not set +# CONFIG_FEATURE_HDPARM_HDIO_UNREGISTER_HWIF is not set +# CONFIG_FEATURE_HDPARM_HDIO_DRIVE_RESET is not set +# CONFIG_FEATURE_HDPARM_HDIO_TRISTATE_HWIF is not set +# CONFIG_FEATURE_HDPARM_HDIO_GETSET_DMA is not set +# CONFIG_HEXEDIT is not set +# CONFIG_I2CGET is not set +# CONFIG_I2CSET is not set +# CONFIG_I2CDUMP is not set +# CONFIG_I2CDETECT is not set +CONFIG_INOTIFYD=y +CONFIG_LESS=y +CONFIG_FEATURE_LESS_MAXLINES=9999999 +CONFIG_FEATURE_LESS_BRACKETS=y +CONFIG_FEATURE_LESS_FLAGS=y +CONFIG_FEATURE_LESS_TRUNCATE=y +CONFIG_FEATURE_LESS_MARKS=y +CONFIG_FEATURE_LESS_REGEXP=y +CONFIG_FEATURE_LESS_WINCH=y +CONFIG_FEATURE_LESS_ASK_TERMINAL=y +CONFIG_FEATURE_LESS_DASHCMD=y +CONFIG_FEATURE_LESS_LINENUMS=y +# CONFIG_LSSCSI is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_FEATURE_MAKEDEVS_LEAF is not set +# CONFIG_FEATURE_MAKEDEVS_TABLE is not set +# CONFIG_MAN is not set +CONFIG_MICROCOM=y +# CONFIG_MT is not set +CONFIG_NANDWRITE=y +CONFIG_NANDDUMP=y +CONFIG_PARTPROBE=y +CONFIG_RAIDAUTORUN=y +CONFIG_READAHEAD=y +CONFIG_RFKILL=y +# CONFIG_RUNLEVEL is not set +# CONFIG_RX is not set +# CONFIG_SETFATTR is not set +CONFIG_SETSERIAL=y +CONFIG_STRINGS=y +CONFIG_TIME=y +CONFIG_TTYSIZE=y +# CONFIG_UBIATTACH is not set +# CONFIG_UBIDETACH is not set +# CONFIG_UBIMKVOL is not set +# CONFIG_UBIRMVOL is not set +# CONFIG_UBIRSVOL is not set +# CONFIG_UBIUPDATEVOL is not set +# CONFIG_UBIRENAME is not set +CONFIG_VOLNAME=y +CONFIG_WATCHDOG=y + +# +# Networking Utilities +# +CONFIG_FEATURE_IPV6=y +CONFIG_FEATURE_UNIX_LOCAL=y +CONFIG_FEATURE_PREFER_IPV4_ADDRESS=y +CONFIG_VERBOSE_RESOLUTION_ERRORS=y +CONFIG_ARP=y +CONFIG_ARPING=y +CONFIG_BRCTL=y +CONFIG_FEATURE_BRCTL_FANCY=y +CONFIG_FEATURE_BRCTL_SHOW=y +# CONFIG_DNSD is not set +CONFIG_ETHER_WAKE=y +# CONFIG_FTPD is not set +# CONFIG_FEATURE_FTPD_WRITE is not set +# CONFIG_FEATURE_FTPD_ACCEPT_BROKEN_LIST is not set +# CONFIG_FEATURE_FTPD_AUTHENTICATION is not set +# CONFIG_FTPGET is not set +# CONFIG_FTPPUT is not set +# CONFIG_FEATURE_FTPGETPUT_LONG_OPTIONS is not set +CONFIG_HOSTNAME=y +CONFIG_DNSDOMAINNAME=y +# CONFIG_HTTPD is not set +# CONFIG_FEATURE_HTTPD_RANGES is not set +# CONFIG_FEATURE_HTTPD_SETUID is not set +# CONFIG_FEATURE_HTTPD_BASIC_AUTH is not set +# CONFIG_FEATURE_HTTPD_AUTH_MD5 is not set +# CONFIG_FEATURE_HTTPD_CGI is not set +# CONFIG_FEATURE_HTTPD_CONFIG_WITH_SCRIPT_INTERPR is not set +# CONFIG_FEATURE_HTTPD_SET_REMOTE_PORT_TO_ENV is not set +# CONFIG_FEATURE_HTTPD_ENCODE_URL_STR is not set +# CONFIG_FEATURE_HTTPD_ERROR_PAGES is not set +# CONFIG_FEATURE_HTTPD_PROXY is not set +# CONFIG_FEATURE_HTTPD_GZIP is not set +CONFIG_IFCONFIG=y +CONFIG_FEATURE_IFCONFIG_STATUS=y +CONFIG_FEATURE_IFCONFIG_SLIP=y +CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ=y +CONFIG_FEATURE_IFCONFIG_HW=y +CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS=y +CONFIG_IFENSLAVE=y +# CONFIG_IFPLUGD is not set +CONFIG_IFUP=y +CONFIG_IFDOWN=y +CONFIG_IFUPDOWN_IFSTATE_PATH="/var/run/ifstate" +CONFIG_FEATURE_IFUPDOWN_IP=y +CONFIG_FEATURE_IFUPDOWN_IPV4=y +CONFIG_FEATURE_IFUPDOWN_IPV6=y +# CONFIG_FEATURE_IFUPDOWN_MAPPING is not set +CONFIG_FEATURE_IFUPDOWN_EXTERNAL_DHCP=y +# CONFIG_INETD is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_ECHO is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_DISCARD is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_TIME is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_DAYTIME is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_CHARGEN is not set +# CONFIG_FEATURE_INETD_RPC is not set +CONFIG_IP=y +CONFIG_IPADDR=y +CONFIG_IPLINK=y +CONFIG_IPROUTE=y +CONFIG_IPTUNNEL=y +CONFIG_IPRULE=y +CONFIG_IPNEIGH=y +CONFIG_FEATURE_IP_ADDRESS=y +CONFIG_FEATURE_IP_LINK=y +CONFIG_FEATURE_IP_ROUTE=y +CONFIG_FEATURE_IP_ROUTE_DIR="/etc/iproute2" +CONFIG_FEATURE_IP_TUNNEL=y +CONFIG_FEATURE_IP_RULE=y +CONFIG_FEATURE_IP_NEIGH=y +CONFIG_FEATURE_IP_RARE_PROTOCOLS=y +CONFIG_IPCALC=y +# CONFIG_FEATURE_IPCALC_LONG_OPTIONS is not set +CONFIG_FEATURE_IPCALC_FANCY=y +# CONFIG_FAKEIDENTD is not set +CONFIG_NAMEIF=y +CONFIG_FEATURE_NAMEIF_EXTENDED=y +CONFIG_NBDCLIENT=y +CONFIG_NC=y +# CONFIG_NETCAT is not set +CONFIG_NC_SERVER=y +CONFIG_NC_EXTRA=y +CONFIG_NC_110_COMPAT=y +CONFIG_NETSTAT=y +CONFIG_FEATURE_NETSTAT_WIDE=y +CONFIG_FEATURE_NETSTAT_PRG=y +CONFIG_NSLOOKUP=y +CONFIG_NTPD=y +CONFIG_FEATURE_NTPD_SERVER=y +CONFIG_FEATURE_NTPD_CONF=y +CONFIG_PING=y +CONFIG_PING6=y +CONFIG_FEATURE_FANCY_PING=y +CONFIG_PSCAN=y +CONFIG_ROUTE=y +CONFIG_SLATTACH=y +# CONFIG_SSL_CLIENT is not set +# CONFIG_TCPSVD is not set +# CONFIG_UDPSVD is not set +# CONFIG_TELNET is not set +# CONFIG_FEATURE_TELNET_TTYPE is not set +# CONFIG_FEATURE_TELNET_AUTOLOGIN is not set +# CONFIG_FEATURE_TELNET_WIDTH is not set +# CONFIG_TELNETD is not set +# CONFIG_FEATURE_TELNETD_STANDALONE is not set +# CONFIG_FEATURE_TELNETD_INETD_WAIT is not set +# CONFIG_TFTP is not set +# CONFIG_FEATURE_TFTP_PROGRESS_BAR is not set +# CONFIG_TFTPD is not set +# CONFIG_FEATURE_TFTP_GET is not set +# CONFIG_FEATURE_TFTP_PUT is not set +# CONFIG_FEATURE_TFTP_BLOCKSIZE is not set +# CONFIG_TFTP_DEBUG is not set +# CONFIG_TLS is not set +CONFIG_TRACEROUTE=y +CONFIG_TRACEROUTE6=y +CONFIG_FEATURE_TRACEROUTE_VERBOSE=y +CONFIG_FEATURE_TRACEROUTE_USE_ICMP=y +CONFIG_TUNCTL=y +CONFIG_FEATURE_TUNCTL_UG=y +CONFIG_VCONFIG=y +CONFIG_WGET=y +CONFIG_FEATURE_WGET_LONG_OPTIONS=y +CONFIG_FEATURE_WGET_STATUSBAR=y +CONFIG_FEATURE_WGET_AUTHENTICATION=y +CONFIG_FEATURE_WGET_TIMEOUT=y +CONFIG_FEATURE_WGET_HTTPS=y +# CONFIG_FEATURE_WGET_OPENSSL is not set +CONFIG_WHOIS=y +# CONFIG_ZCIP is not set +# CONFIG_UDHCPD is not set +# CONFIG_FEATURE_UDHCPD_BASE_IP_ON_MAC is not set +# CONFIG_FEATURE_UDHCPD_WRITE_LEASES_EARLY is not set +CONFIG_DHCPD_LEASES_FILE="" +CONFIG_DUMPLEASES=y +# CONFIG_DHCPRELAY is not set +CONFIG_UDHCPC=y +CONFIG_FEATURE_UDHCPC_ARPING=y +CONFIG_FEATURE_UDHCPC_SANITIZEOPT=y +CONFIG_UDHCPC_DEFAULT_SCRIPT="/usr/share/udhcpc/default.script" +CONFIG_UDHCPC6=y +CONFIG_FEATURE_UDHCPC6_RFC3646=y +CONFIG_FEATURE_UDHCPC6_RFC4704=y +CONFIG_FEATURE_UDHCPC6_RFC4833=y + +# +# Common options for DHCP applets +# +# CONFIG_FEATURE_UDHCP_PORT is not set +CONFIG_UDHCP_DEBUG=0 +CONFIG_UDHCPC_SLACK_FOR_BUGGY_SERVERS=80 +CONFIG_FEATURE_UDHCP_RFC3397=y +CONFIG_FEATURE_UDHCP_8021Q=y +CONFIG_IFUPDOWN_UDHCPC_CMD_OPTIONS="-b" + +# +# Print Utilities +# +# CONFIG_LPD is not set +# CONFIG_LPR is not set +# CONFIG_LPQ is not set + +# +# Mail Utilities +# +CONFIG_MAKEMIME=y +# CONFIG_POPMAILDIR is not set +# CONFIG_FEATURE_POPMAILDIR_DELIVERY is not set +CONFIG_REFORMIME=y +CONFIG_FEATURE_REFORMIME_COMPAT=y +CONFIG_SENDMAIL=y +CONFIG_FEATURE_MIME_CHARSET="us-ascii" + +# +# Process Utilities +# +CONFIG_FREE=y +CONFIG_FUSER=y +CONFIG_IOSTAT=y +CONFIG_KILL=y +CONFIG_KILLALL=y +CONFIG_KILLALL5=y +CONFIG_LSOF=y +CONFIG_MPSTAT=y +CONFIG_NMETER=y +CONFIG_PGREP=y +CONFIG_PKILL=y +CONFIG_PIDOF=y +CONFIG_FEATURE_PIDOF_SINGLE=y +CONFIG_FEATURE_PIDOF_OMIT=y +CONFIG_PMAP=y +CONFIG_POWERTOP=y +CONFIG_FEATURE_POWERTOP_INTERACTIVE=y +CONFIG_PS=y +# CONFIG_FEATURE_PS_WIDE is not set +# CONFIG_FEATURE_PS_LONG is not set +CONFIG_FEATURE_PS_TIME=y +# CONFIG_FEATURE_PS_UNUSUAL_SYSTEMS is not set +CONFIG_FEATURE_PS_ADDITIONAL_COLUMNS=y +CONFIG_PSTREE=y +CONFIG_PWDX=y +CONFIG_SMEMCAP=y +CONFIG_BB_SYSCTL=y +CONFIG_TOP=y +CONFIG_FEATURE_TOP_INTERACTIVE=y +CONFIG_FEATURE_TOP_CPU_USAGE_PERCENTAGE=y +CONFIG_FEATURE_TOP_CPU_GLOBAL_PERCENTS=y +CONFIG_FEATURE_TOP_SMP_CPU=y +# CONFIG_FEATURE_TOP_DECIMALS is not set +CONFIG_FEATURE_TOP_SMP_PROCESS=y +CONFIG_FEATURE_TOPMEM=y +CONFIG_UPTIME=y +# CONFIG_FEATURE_UPTIME_UTMP_SUPPORT is not set +CONFIG_WATCH=y +# CONFIG_FEATURE_SHOW_THREADS is not set + +# +# Runit Utilities +# +# CONFIG_CHPST is not set +# CONFIG_SETUIDGID is not set +# CONFIG_ENVUIDGID is not set +# CONFIG_ENVDIR is not set +# CONFIG_SOFTLIMIT is not set +# CONFIG_RUNSV is not set +# CONFIG_RUNSVDIR is not set +# CONFIG_FEATURE_RUNSVDIR_LOG is not set +# CONFIG_SV is not set +CONFIG_SV_DEFAULT_SERVICE_DIR="" +# CONFIG_SVC is not set +# CONFIG_SVLOGD is not set +# CONFIG_CHCON is not set +# CONFIG_GETENFORCE is not set +# CONFIG_GETSEBOOL is not set +# CONFIG_LOAD_POLICY is not set +# CONFIG_MATCHPATHCON is not set +# CONFIG_RUNCON is not set +# CONFIG_SELINUXENABLED is not set +# CONFIG_SESTATUS is not set +# CONFIG_SETENFORCE is not set +# CONFIG_SETFILES is not set +# CONFIG_FEATURE_SETFILES_CHECK_OPTION is not set +# CONFIG_RESTORECON is not set +# CONFIG_SETSEBOOL is not set + +# +# Shells +# +CONFIG_SH_IS_ASH=y +# CONFIG_SH_IS_HUSH is not set +# CONFIG_SH_IS_NONE is not set +# CONFIG_BASH_IS_ASH is not set +# CONFIG_BASH_IS_HUSH is not set +CONFIG_BASH_IS_NONE=y +CONFIG_ASH=y +CONFIG_ASH_OPTIMIZE_FOR_SIZE=y +CONFIG_ASH_INTERNAL_GLOB=y +CONFIG_ASH_BASH_COMPAT=y +CONFIG_ASH_JOB_CONTROL=y +CONFIG_ASH_ALIAS=y +CONFIG_ASH_RANDOM_SUPPORT=y +CONFIG_ASH_EXPAND_PRMT=y +CONFIG_ASH_IDLE_TIMEOUT=y +CONFIG_ASH_MAIL=y +CONFIG_ASH_ECHO=y +CONFIG_ASH_PRINTF=y +CONFIG_ASH_TEST=y +CONFIG_ASH_HELP=y +CONFIG_ASH_GETOPTS=y +CONFIG_ASH_CMDCMD=y +CONFIG_ASH_BASH_SOURCE_CURDIR=y +CONFIG_ASH_COMMAND_NOT_FOUND_HOOK=y +# CONFIG_CTTYHACK is not set +# CONFIG_HUSH is not set +# CONFIG_HUSH_BASH_COMPAT is not set +# CONFIG_HUSH_BRACE_EXPANSION is not set +# CONFIG_HUSH_INTERACTIVE is not set +# CONFIG_HUSH_SAVEHISTORY is not set +# CONFIG_HUSH_JOB is not set +# CONFIG_HUSH_TICK is not set +# CONFIG_HUSH_IF is not set +# CONFIG_HUSH_LOOPS is not set +# CONFIG_HUSH_CASE is not set +# CONFIG_HUSH_FUNCTIONS is not set +# CONFIG_HUSH_LOCAL is not set +# CONFIG_HUSH_RANDOM_SUPPORT is not set +# CONFIG_HUSH_MODE_X is not set +# CONFIG_HUSH_ECHO is not set +# CONFIG_HUSH_PRINTF is not set +# CONFIG_HUSH_TEST is not set +# CONFIG_HUSH_HELP is not set +# CONFIG_HUSH_EXPORT is not set +# CONFIG_HUSH_EXPORT_N is not set +# CONFIG_HUSH_READONLY is not set +# CONFIG_HUSH_KILL is not set +# CONFIG_HUSH_WAIT is not set +# CONFIG_HUSH_TRAP is not set +# CONFIG_HUSH_TYPE is not set +# CONFIG_HUSH_TIMES is not set +# CONFIG_HUSH_READ is not set +# CONFIG_HUSH_SET is not set +# CONFIG_HUSH_UNSET is not set +# CONFIG_HUSH_ULIMIT is not set +# CONFIG_HUSH_UMASK is not set +# CONFIG_HUSH_GETOPTS is not set +# CONFIG_HUSH_MEMLEAK is not set + +# +# Options common to all shells +# +CONFIG_FEATURE_SH_MATH=y +CONFIG_FEATURE_SH_MATH_64=y +CONFIG_FEATURE_SH_EXTRA_QUIET=y +# CONFIG_FEATURE_SH_STANDALONE is not set +# CONFIG_FEATURE_SH_NOFORK is not set +CONFIG_FEATURE_SH_READ_FRAC=y +CONFIG_FEATURE_SH_HISTFILESIZE=y + +# +# System Logging Utilities +# +CONFIG_KLOGD=y + +# +# klogd should not be used together with syslog to kernel printk buffer +# +CONFIG_FEATURE_KLOGD_KLOGCTL=y +CONFIG_LOGGER=y +CONFIG_LOGREAD=y +CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING=y +CONFIG_SYSLOGD=y +CONFIG_FEATURE_ROTATE_LOGFILE=y +CONFIG_FEATURE_REMOTE_LOG=y +CONFIG_FEATURE_SYSLOGD_DUP=y +CONFIG_FEATURE_SYSLOGD_CFG=y +CONFIG_FEATURE_SYSLOGD_READ_BUFFER_SIZE=256 +CONFIG_FEATURE_IPC_SYSLOG=y +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=16 +CONFIG_FEATURE_KMSG_SYSLOG=y diff --git a/legacy/busybox/busyboxconfig-extras b/legacy/busybox/busyboxconfig-extras new file mode 100644 index 000000000..ed9c572a9 --- /dev/null +++ b/legacy/busybox/busyboxconfig-extras @@ -0,0 +1,1131 @@ +# +# Automatically generated make config: don't edit +# Busybox version: 1.28.2 +# Wed Mar 28 12:24:25 2018 +# +CONFIG_HAVE_DOT_CONFIG=y + +# +# Settings +# +# CONFIG_DESKTOP is not set +# CONFIG_EXTRA_COMPAT is not set +# CONFIG_FEDORA_COMPAT is not set +# CONFIG_INCLUDE_SUSv2 is not set +# CONFIG_LONG_OPTS is not set +CONFIG_SHOW_USAGE=y +CONFIG_FEATURE_VERBOSE_USAGE=y +CONFIG_FEATURE_COMPRESS_USAGE=y +CONFIG_LFS=y +# CONFIG_PAM is not set +CONFIG_FEATURE_DEVPTS=y +# CONFIG_FEATURE_UTMP is not set +# CONFIG_FEATURE_WTMP is not set +# CONFIG_FEATURE_PIDFILE is not set +CONFIG_PID_FILE_PATH="" +CONFIG_BUSYBOX=y +CONFIG_FEATURE_INSTALLER=y +# CONFIG_INSTALL_NO_USR is not set +# CONFIG_FEATURE_SUID is not set +# CONFIG_FEATURE_SUID_CONFIG is not set +# CONFIG_FEATURE_SUID_CONFIG_QUIET is not set +# CONFIG_FEATURE_PREFER_APPLETS is not set +CONFIG_BUSYBOX_EXEC_PATH="/proc/self/exe" +# CONFIG_SELINUX is not set +# CONFIG_FEATURE_CLEAN_UP is not set +CONFIG_FEATURE_SYSLOG=y +CONFIG_PLATFORM_LINUX=y + +# +# Build Options +# +# CONFIG_STATIC is not set +CONFIG_PIE=y +# CONFIG_NOMMU is not set +# CONFIG_BUILD_LIBBUSYBOX is not set +# CONFIG_FEATURE_LIBBUSYBOX_STATIC is not set +# CONFIG_FEATURE_INDIVIDUAL is not set +# CONFIG_FEATURE_SHARED_BUSYBOX is not set +CONFIG_CROSS_COMPILER_PREFIX="" +CONFIG_SYSROOT="" +CONFIG_EXTRA_CFLAGS="" +CONFIG_EXTRA_LDFLAGS="" +CONFIG_EXTRA_LDLIBS="" +# CONFIG_USE_PORTABLE_CODE is not set + +# +# Installation Options ("make install" behavior) +# +CONFIG_INSTALL_APPLET_SYMLINKS=y +# CONFIG_INSTALL_APPLET_HARDLINKS is not set +# CONFIG_INSTALL_APPLET_SCRIPT_WRAPPERS is not set +# CONFIG_INSTALL_APPLET_DONT is not set +# CONFIG_INSTALL_SH_APPLET_SYMLINK is not set +# CONFIG_INSTALL_SH_APPLET_HARDLINK is not set +# CONFIG_INSTALL_SH_APPLET_SCRIPT_WRAPPER is not set +CONFIG_PREFIX="./_install" + +# +# Debugging Options +# +# CONFIG_DEBUG is not set +# CONFIG_DEBUG_PESSIMIZE is not set +# CONFIG_DEBUG_SANITIZE is not set +# CONFIG_UNIT_TEST is not set +# CONFIG_WERROR is not set +CONFIG_NO_DEBUG_LIB=y +# CONFIG_DMALLOC is not set +# CONFIG_EFENCE is not set + +# +# Library Tuning +# +# CONFIG_FEATURE_USE_BSS_TAIL is not set +# CONFIG_FEATURE_RTMINMAX is not set +CONFIG_FEATURE_BUFFERS_USE_MALLOC=y +# CONFIG_FEATURE_BUFFERS_GO_ON_STACK is not set +# CONFIG_FEATURE_BUFFERS_GO_IN_BSS is not set +CONFIG_PASSWORD_MINLEN=6 +CONFIG_MD5_SMALL=1 +CONFIG_SHA3_SMALL=1 +# CONFIG_FEATURE_FAST_TOP is not set +# CONFIG_FEATURE_ETC_NETWORKS is not set +# CONFIG_FEATURE_EDITING is not set +CONFIG_FEATURE_EDITING_MAX_LEN=0 +# CONFIG_FEATURE_EDITING_VI is not set +CONFIG_FEATURE_EDITING_HISTORY=0 +# CONFIG_FEATURE_EDITING_SAVEHISTORY is not set +# CONFIG_FEATURE_EDITING_SAVE_ON_EXIT is not set +# CONFIG_FEATURE_REVERSE_SEARCH is not set +# CONFIG_FEATURE_TAB_COMPLETION is not set +# CONFIG_FEATURE_USERNAME_COMPLETION is not set +# CONFIG_FEATURE_EDITING_FANCY_PROMPT is not set +# CONFIG_FEATURE_EDITING_ASK_TERMINAL is not set +# CONFIG_LOCALE_SUPPORT is not set +# CONFIG_UNICODE_SUPPORT is not set +# CONFIG_UNICODE_USING_LOCALE is not set +# CONFIG_FEATURE_CHECK_UNICODE_IN_ENV is not set +CONFIG_SUBST_WCHAR=0 +CONFIG_LAST_SUPPORTED_WCHAR=0 +# CONFIG_UNICODE_COMBINING_WCHARS is not set +# CONFIG_UNICODE_WIDE_WCHARS is not set +# CONFIG_UNICODE_BIDI_SUPPORT is not set +# CONFIG_UNICODE_NEUTRAL_TABLE is not set +# CONFIG_UNICODE_PRESERVE_BROKEN is not set +# CONFIG_FEATURE_NON_POSIX_CP is not set +# CONFIG_FEATURE_VERBOSE_CP_MESSAGE is not set +# CONFIG_FEATURE_USE_SENDFILE is not set +CONFIG_FEATURE_COPYBUF_KB=4 +# CONFIG_FEATURE_SKIP_ROOTFS is not set +# CONFIG_MONOTONIC_SYSCALL is not set +# CONFIG_IOCTL_HEX2STR_ERROR is not set +# CONFIG_FEATURE_HWIB is not set + +# +# Applets +# + +# +# Archival Utilities +# +# CONFIG_FEATURE_SEAMLESS_XZ is not set +# CONFIG_FEATURE_SEAMLESS_LZMA is not set +# CONFIG_FEATURE_SEAMLESS_BZ2 is not set +CONFIG_FEATURE_SEAMLESS_GZ=y +# CONFIG_FEATURE_SEAMLESS_Z is not set +# CONFIG_AR is not set +# CONFIG_FEATURE_AR_LONG_FILENAMES is not set +# CONFIG_FEATURE_AR_CREATE is not set +# CONFIG_UNCOMPRESS is not set +# CONFIG_GUNZIP is not set +# CONFIG_ZCAT is not set +# CONFIG_FEATURE_GUNZIP_LONG_OPTIONS is not set +# CONFIG_BUNZIP2 is not set +# CONFIG_BZCAT is not set +# CONFIG_UNLZMA is not set +# CONFIG_LZCAT is not set +# CONFIG_LZMA is not set +# CONFIG_UNXZ is not set +# CONFIG_XZCAT is not set +# CONFIG_XZ is not set +# CONFIG_BZIP2 is not set +# CONFIG_FEATURE_BZIP2_DECOMPRESS is not set +# CONFIG_CPIO is not set +# CONFIG_FEATURE_CPIO_O is not set +# CONFIG_FEATURE_CPIO_P is not set +# CONFIG_DPKG is not set +# CONFIG_DPKG_DEB is not set +# CONFIG_GZIP is not set +# CONFIG_FEATURE_GZIP_LONG_OPTIONS is not set +CONFIG_GZIP_FAST=0 +# CONFIG_FEATURE_GZIP_LEVELS is not set +# CONFIG_FEATURE_GZIP_DECOMPRESS is not set +# CONFIG_LZOP is not set +# CONFIG_UNLZOP is not set +# CONFIG_LZOPCAT is not set +# CONFIG_LZOP_COMPR_HIGH is not set +# CONFIG_RPM is not set +# CONFIG_RPM2CPIO is not set +# CONFIG_TAR is not set +# CONFIG_FEATURE_TAR_LONG_OPTIONS is not set +# CONFIG_FEATURE_TAR_CREATE is not set +# CONFIG_FEATURE_TAR_AUTODETECT is not set +# CONFIG_FEATURE_TAR_FROM is not set +# CONFIG_FEATURE_TAR_OLDGNU_COMPATIBILITY is not set +# CONFIG_FEATURE_TAR_OLDSUN_COMPATIBILITY is not set +# CONFIG_FEATURE_TAR_GNU_EXTENSIONS is not set +# CONFIG_FEATURE_TAR_TO_COMMAND is not set +# CONFIG_FEATURE_TAR_UNAME_GNAME is not set +# CONFIG_FEATURE_TAR_NOPRESERVE_TIME is not set +# CONFIG_FEATURE_TAR_SELINUX is not set +# CONFIG_UNZIP is not set +# CONFIG_FEATURE_UNZIP_CDF is not set +# CONFIG_FEATURE_UNZIP_BZIP2 is not set +# CONFIG_FEATURE_UNZIP_LZMA is not set +# CONFIG_FEATURE_UNZIP_XZ is not set +# CONFIG_FEATURE_LZMA_FAST is not set + +# +# Coreutils +# +# CONFIG_BASENAME is not set +# CONFIG_CAT is not set +# CONFIG_FEATURE_CATN is not set +# CONFIG_FEATURE_CATV is not set +# CONFIG_CHGRP is not set +# CONFIG_CHMOD is not set +# CONFIG_CHOWN is not set +# CONFIG_FEATURE_CHOWN_LONG_OPTIONS is not set +# CONFIG_CHROOT is not set +# CONFIG_CKSUM is not set +# CONFIG_COMM is not set +# CONFIG_CP is not set +# CONFIG_FEATURE_CP_LONG_OPTIONS is not set +# CONFIG_CUT is not set +# CONFIG_DATE is not set +# CONFIG_FEATURE_DATE_ISOFMT is not set +# CONFIG_FEATURE_DATE_NANO is not set +# CONFIG_FEATURE_DATE_COMPAT is not set +# CONFIG_DD is not set +# CONFIG_FEATURE_DD_SIGNAL_HANDLING is not set +# CONFIG_FEATURE_DD_THIRD_STATUS_LINE is not set +# CONFIG_FEATURE_DD_IBS_OBS is not set +# CONFIG_FEATURE_DD_STATUS is not set +# CONFIG_DF is not set +# CONFIG_FEATURE_DF_FANCY is not set +# CONFIG_DIRNAME is not set +# CONFIG_DOS2UNIX is not set +# CONFIG_UNIX2DOS is not set +# CONFIG_DU is not set +# CONFIG_FEATURE_DU_DEFAULT_BLOCKSIZE_1K is not set +# CONFIG_ECHO is not set +# CONFIG_FEATURE_FANCY_ECHO is not set +# CONFIG_ENV is not set +# CONFIG_EXPAND is not set +# CONFIG_UNEXPAND is not set +# CONFIG_EXPR is not set +# CONFIG_EXPR_MATH_SUPPORT_64 is not set +# CONFIG_FACTOR is not set +# CONFIG_FALSE is not set +# CONFIG_FOLD is not set +# CONFIG_FSYNC is not set +# CONFIG_HEAD is not set +# CONFIG_FEATURE_FANCY_HEAD is not set +# CONFIG_HOSTID is not set +# CONFIG_ID is not set +# CONFIG_GROUPS is not set +# CONFIG_INSTALL is not set +# CONFIG_FEATURE_INSTALL_LONG_OPTIONS is not set +# CONFIG_LINK is not set +# CONFIG_LN is not set +# CONFIG_LOGNAME is not set +# CONFIG_LS is not set +# CONFIG_FEATURE_LS_FILETYPES is not set +# CONFIG_FEATURE_LS_FOLLOWLINKS is not set +# CONFIG_FEATURE_LS_RECURSIVE is not set +# CONFIG_FEATURE_LS_WIDTH is not set +# CONFIG_FEATURE_LS_SORTFILES is not set +# CONFIG_FEATURE_LS_TIMESTAMPS is not set +# CONFIG_FEATURE_LS_USERNAME is not set +# CONFIG_FEATURE_LS_COLOR is not set +# CONFIG_FEATURE_LS_COLOR_IS_DEFAULT is not set +# CONFIG_MD5SUM is not set +# CONFIG_SHA1SUM is not set +# CONFIG_SHA256SUM is not set +# CONFIG_SHA512SUM is not set +# CONFIG_SHA3SUM is not set +# CONFIG_FEATURE_MD5_SHA1_SUM_CHECK is not set +# CONFIG_MKDIR is not set +# CONFIG_MKFIFO is not set +# CONFIG_MKNOD is not set +# CONFIG_MKTEMP is not set +# CONFIG_MV is not set +# CONFIG_NICE is not set +# CONFIG_NL is not set +# CONFIG_NOHUP is not set +# CONFIG_NPROC is not set +# CONFIG_OD is not set +# CONFIG_PASTE is not set +# CONFIG_PRINTENV is not set +# CONFIG_PRINTF is not set +# CONFIG_PWD is not set +# CONFIG_READLINK is not set +# CONFIG_FEATURE_READLINK_FOLLOW is not set +# CONFIG_REALPATH is not set +# CONFIG_RM is not set +# CONFIG_RMDIR is not set +# CONFIG_SEQ is not set +# CONFIG_SHRED is not set +# CONFIG_SHUF is not set +# CONFIG_SLEEP is not set +# CONFIG_FEATURE_FANCY_SLEEP is not set +# CONFIG_FEATURE_FLOAT_SLEEP is not set +# CONFIG_SORT is not set +# CONFIG_FEATURE_SORT_BIG is not set +# CONFIG_SPLIT is not set +# CONFIG_FEATURE_SPLIT_FANCY is not set +# CONFIG_STAT is not set +# CONFIG_FEATURE_STAT_FORMAT is not set +# CONFIG_FEATURE_STAT_FILESYSTEM is not set +# CONFIG_STTY is not set +# CONFIG_SUM is not set +# CONFIG_SYNC is not set +# CONFIG_FEATURE_SYNC_FANCY is not set +# CONFIG_TAC is not set +# CONFIG_TAIL is not set +# CONFIG_FEATURE_FANCY_TAIL is not set +# CONFIG_TEE is not set +# CONFIG_FEATURE_TEE_USE_BLOCK_IO is not set +# CONFIG_TEST is not set +# CONFIG_TEST1 is not set +# CONFIG_TEST2 is not set +# CONFIG_FEATURE_TEST_64 is not set +# CONFIG_TIMEOUT is not set +# CONFIG_TOUCH is not set +# CONFIG_FEATURE_TOUCH_NODEREF is not set +# CONFIG_FEATURE_TOUCH_SUSV3 is not set +# CONFIG_TR is not set +# CONFIG_FEATURE_TR_CLASSES is not set +# CONFIG_FEATURE_TR_EQUIV is not set +# CONFIG_TRUE is not set +# CONFIG_TRUNCATE is not set +# CONFIG_TTY is not set +# CONFIG_UNAME is not set +CONFIG_UNAME_OSNAME="" +CONFIG_BB_ARCH=y +# CONFIG_UNIQ is not set +# CONFIG_UNLINK is not set +# CONFIG_USLEEP is not set +# CONFIG_UUDECODE is not set +# CONFIG_BASE64 is not set +# CONFIG_UUENCODE is not set +# CONFIG_WC is not set +# CONFIG_FEATURE_WC_LARGE is not set +# CONFIG_WHO is not set +# CONFIG_W is not set +# CONFIG_USERS is not set +# CONFIG_WHOAMI is not set +# CONFIG_YES is not set + +# +# Common options +# +# CONFIG_FEATURE_VERBOSE is not set +# CONFIG_FEATURE_PRESERVE_HARDLINKS is not set +# CONFIG_FEATURE_HUMAN_READABLE is not set + +# +# Console Utilities +# +# CONFIG_CHVT is not set +# CONFIG_CLEAR is not set +# CONFIG_DEALLOCVT is not set +# CONFIG_DUMPKMAP is not set +# CONFIG_FGCONSOLE is not set +# CONFIG_KBD_MODE is not set +# CONFIG_LOADFONT is not set +# CONFIG_SETFONT is not set +# CONFIG_FEATURE_SETFONT_TEXTUAL_MAP is not set +CONFIG_DEFAULT_SETFONT_DIR="" +# CONFIG_FEATURE_LOADFONT_PSF2 is not set +# CONFIG_FEATURE_LOADFONT_RAW is not set +# CONFIG_LOADKMAP is not set +# CONFIG_OPENVT is not set +# CONFIG_RESET is not set +# CONFIG_RESIZE is not set +# CONFIG_FEATURE_RESIZE_PRINT is not set +# CONFIG_SETCONSOLE is not set +# CONFIG_FEATURE_SETCONSOLE_LONG_OPTIONS is not set +# CONFIG_SETKEYCODES is not set +# CONFIG_SETLOGCONS is not set +# CONFIG_SHOWKEY is not set + +# +# Debian Utilities +# +# CONFIG_PIPE_PROGRESS is not set +# CONFIG_RUN_PARTS is not set +# CONFIG_FEATURE_RUN_PARTS_LONG_OPTIONS is not set +# CONFIG_FEATURE_RUN_PARTS_FANCY is not set +# CONFIG_START_STOP_DAEMON is not set +# CONFIG_FEATURE_START_STOP_DAEMON_LONG_OPTIONS is not set +# CONFIG_FEATURE_START_STOP_DAEMON_FANCY is not set +# CONFIG_WHICH is not set + +# +# klibc-utils +# +# CONFIG_MINIPS is not set +# CONFIG_NUKE is not set +# CONFIG_RESUME is not set +# CONFIG_RUN_INIT is not set + +# +# Editors +# +# CONFIG_AWK is not set +# CONFIG_FEATURE_AWK_LIBM is not set +# CONFIG_FEATURE_AWK_GNU_EXTENSIONS is not set +# CONFIG_CMP is not set +# CONFIG_DIFF is not set +# CONFIG_FEATURE_DIFF_LONG_OPTIONS is not set +# CONFIG_FEATURE_DIFF_DIR is not set +# CONFIG_ED is not set +# CONFIG_PATCH is not set +# CONFIG_SED is not set +# CONFIG_VI is not set +CONFIG_FEATURE_VI_MAX_LEN=0 +# CONFIG_FEATURE_VI_8BIT is not set +# CONFIG_FEATURE_VI_COLON is not set +# CONFIG_FEATURE_VI_YANKMARK is not set +# CONFIG_FEATURE_VI_SEARCH is not set +# CONFIG_FEATURE_VI_REGEX_SEARCH is not set +# CONFIG_FEATURE_VI_USE_SIGNALS is not set +# CONFIG_FEATURE_VI_DOT_CMD is not set +# CONFIG_FEATURE_VI_READONLY is not set +# CONFIG_FEATURE_VI_SETOPTS is not set +# CONFIG_FEATURE_VI_SET is not set +# CONFIG_FEATURE_VI_WIN_RESIZE is not set +# CONFIG_FEATURE_VI_ASK_TERMINAL is not set +# CONFIG_FEATURE_VI_UNDO is not set +# CONFIG_FEATURE_VI_UNDO_QUEUE is not set +CONFIG_FEATURE_VI_UNDO_QUEUE_MAX=0 +# CONFIG_FEATURE_ALLOW_EXEC is not set + +# +# Finding Utilities +# +# CONFIG_FIND is not set +# CONFIG_FEATURE_FIND_PRINT0 is not set +# CONFIG_FEATURE_FIND_MTIME is not set +# CONFIG_FEATURE_FIND_MMIN is not set +# CONFIG_FEATURE_FIND_PERM is not set +# CONFIG_FEATURE_FIND_TYPE is not set +# CONFIG_FEATURE_FIND_XDEV is not set +# CONFIG_FEATURE_FIND_MAXDEPTH is not set +# CONFIG_FEATURE_FIND_NEWER is not set +# CONFIG_FEATURE_FIND_INUM is not set +# CONFIG_FEATURE_FIND_EXEC is not set +# CONFIG_FEATURE_FIND_EXEC_PLUS is not set +# CONFIG_FEATURE_FIND_USER is not set +# CONFIG_FEATURE_FIND_GROUP is not set +# CONFIG_FEATURE_FIND_NOT is not set +# CONFIG_FEATURE_FIND_DEPTH is not set +# CONFIG_FEATURE_FIND_PAREN is not set +# CONFIG_FEATURE_FIND_SIZE is not set +# CONFIG_FEATURE_FIND_PRUNE is not set +# CONFIG_FEATURE_FIND_DELETE is not set +# CONFIG_FEATURE_FIND_PATH is not set +# CONFIG_FEATURE_FIND_REGEX is not set +# CONFIG_FEATURE_FIND_CONTEXT is not set +# CONFIG_FEATURE_FIND_LINKS is not set +# CONFIG_GREP is not set +# CONFIG_EGREP is not set +# CONFIG_FGREP is not set +# CONFIG_FEATURE_GREP_CONTEXT is not set +# CONFIG_XARGS is not set +# CONFIG_FEATURE_XARGS_SUPPORT_CONFIRMATION is not set +# CONFIG_FEATURE_XARGS_SUPPORT_QUOTES is not set +# CONFIG_FEATURE_XARGS_SUPPORT_TERMOPT is not set +# CONFIG_FEATURE_XARGS_SUPPORT_ZERO_TERM is not set +# CONFIG_FEATURE_XARGS_SUPPORT_REPL_STR is not set +# CONFIG_FEATURE_XARGS_SUPPORT_PARALLEL is not set +# CONFIG_FEATURE_XARGS_SUPPORT_ARGS_FILE is not set + +# +# Init Utilities +# +# CONFIG_BOOTCHARTD is not set +# CONFIG_FEATURE_BOOTCHARTD_BLOATED_HEADER is not set +# CONFIG_FEATURE_BOOTCHARTD_CONFIG_FILE is not set +# CONFIG_HALT is not set +# CONFIG_POWEROFF is not set +# CONFIG_REBOOT is not set +# CONFIG_FEATURE_CALL_TELINIT is not set +CONFIG_TELINIT_PATH="" +# CONFIG_INIT is not set +# CONFIG_LINUXRC is not set +# CONFIG_FEATURE_USE_INITTAB is not set +# CONFIG_FEATURE_KILL_REMOVED is not set +CONFIG_FEATURE_KILL_DELAY=0 +# CONFIG_FEATURE_INIT_SCTTY is not set +# CONFIG_FEATURE_INIT_SYSLOG is not set +# CONFIG_FEATURE_INIT_QUIET is not set +# CONFIG_FEATURE_INIT_COREDUMPS is not set +CONFIG_INIT_TERMINAL_TYPE="" +# CONFIG_FEATURE_INIT_MODIFY_CMDLINE is not set + +# +# Login/Password Management Utilities +# +# CONFIG_FEATURE_SHADOWPASSWDS is not set +# CONFIG_USE_BB_PWD_GRP is not set +# CONFIG_USE_BB_SHADOW is not set +# CONFIG_USE_BB_CRYPT is not set +# CONFIG_USE_BB_CRYPT_SHA is not set +# CONFIG_ADD_SHELL is not set +# CONFIG_REMOVE_SHELL is not set +# CONFIG_ADDGROUP is not set +# CONFIG_FEATURE_ADDUSER_TO_GROUP is not set +# CONFIG_ADDUSER is not set +# CONFIG_FEATURE_CHECK_NAMES is not set +CONFIG_LAST_ID=0 +CONFIG_FIRST_SYSTEM_ID=0 +CONFIG_LAST_SYSTEM_ID=0 +# CONFIG_CHPASSWD is not set +CONFIG_FEATURE_DEFAULT_PASSWD_ALGO="" +# CONFIG_CRYPTPW is not set +# CONFIG_MKPASSWD is not set +# CONFIG_DELUSER is not set +# CONFIG_DELGROUP is not set +# CONFIG_FEATURE_DEL_USER_FROM_GROUP is not set +# CONFIG_GETTY is not set +# CONFIG_LOGIN is not set +# CONFIG_LOGIN_SESSION_AS_CHILD is not set +# CONFIG_LOGIN_SCRIPTS is not set +# CONFIG_FEATURE_NOLOGIN is not set +# CONFIG_FEATURE_SECURETTY is not set +# CONFIG_NOLOGIN is not set +# CONFIG_PASSWD is not set +# CONFIG_FEATURE_PASSWD_WEAK_CHECK is not set +# CONFIG_SU is not set +# CONFIG_FEATURE_SU_SYSLOG is not set +# CONFIG_FEATURE_SU_CHECKS_SHELLS is not set +# CONFIG_FEATURE_SU_BLANK_PW_NEEDS_SECURE_TTY is not set +# CONFIG_SULOGIN is not set +# CONFIG_VLOCK is not set + +# +# Linux Ext2 FS Progs +# +# CONFIG_CHATTR is not set +# CONFIG_FSCK is not set +# CONFIG_LSATTR is not set +# CONFIG_TUNE2FS is not set + +# +# Linux Module Utilities +# +# CONFIG_MODPROBE_SMALL is not set +# CONFIG_DEPMOD is not set +# CONFIG_INSMOD is not set +# CONFIG_LSMOD is not set +# CONFIG_FEATURE_LSMOD_PRETTY_2_6_OUTPUT is not set +# CONFIG_MODINFO is not set +# CONFIG_MODPROBE is not set +# CONFIG_FEATURE_MODPROBE_BLACKLIST is not set +# CONFIG_RMMOD is not set + +# +# Options common to multiple modutils +# +# CONFIG_FEATURE_CMDLINE_MODULE_OPTIONS is not set +# CONFIG_FEATURE_MODPROBE_SMALL_CHECK_ALREADY_LOADED is not set +# CONFIG_FEATURE_2_4_MODULES is not set +# CONFIG_FEATURE_INSMOD_VERSION_CHECKING is not set +# CONFIG_FEATURE_INSMOD_KSYMOOPS_SYMBOLS is not set +# CONFIG_FEATURE_INSMOD_LOADINKMEM is not set +# CONFIG_FEATURE_INSMOD_LOAD_MAP is not set +# CONFIG_FEATURE_INSMOD_LOAD_MAP_FULL is not set +# CONFIG_FEATURE_CHECK_TAINTED_MODULE is not set +# CONFIG_FEATURE_INSMOD_TRY_MMAP is not set +# CONFIG_FEATURE_MODUTILS_ALIAS is not set +# CONFIG_FEATURE_MODUTILS_BIN is not set +# CONFIG_FEATURE_MODUTILS_SYMBOLS is not set +CONFIG_DEFAULT_MODULES_DIR="" +CONFIG_DEFAULT_DEPMOD_FILE="" + +# +# Linux System Utilities +# +# CONFIG_ACPID is not set +# CONFIG_FEATURE_ACPID_COMPAT is not set +# CONFIG_BLKDISCARD is not set +# CONFIG_BLKID is not set +# CONFIG_FEATURE_BLKID_TYPE is not set +# CONFIG_BLOCKDEV is not set +# CONFIG_CAL is not set +# CONFIG_CHRT is not set +# CONFIG_DMESG is not set +# CONFIG_FEATURE_DMESG_PRETTY is not set +# CONFIG_EJECT is not set +# CONFIG_FEATURE_EJECT_SCSI is not set +# CONFIG_FALLOCATE is not set +# CONFIG_FATATTR is not set +# CONFIG_FBSET is not set +# CONFIG_FEATURE_FBSET_FANCY is not set +# CONFIG_FEATURE_FBSET_READMODE is not set +# CONFIG_FDFORMAT is not set +# CONFIG_FDISK is not set +# CONFIG_FDISK_SUPPORT_LARGE_DISKS is not set +# CONFIG_FEATURE_FDISK_WRITABLE is not set +# CONFIG_FEATURE_AIX_LABEL is not set +# CONFIG_FEATURE_SGI_LABEL is not set +# CONFIG_FEATURE_SUN_LABEL is not set +# CONFIG_FEATURE_OSF_LABEL is not set +# CONFIG_FEATURE_GPT_LABEL is not set +# CONFIG_FEATURE_FDISK_ADVANCED is not set +# CONFIG_FINDFS is not set +# CONFIG_FLOCK is not set +# CONFIG_FDFLUSH is not set +# CONFIG_FREERAMDISK is not set +# CONFIG_FSCK_MINIX is not set +# CONFIG_FSFREEZE is not set +# CONFIG_FSTRIM is not set +# CONFIG_GETOPT is not set +# CONFIG_FEATURE_GETOPT_LONG is not set +# CONFIG_HEXDUMP is not set +# CONFIG_FEATURE_HEXDUMP_REVERSE is not set +# CONFIG_HD is not set +# CONFIG_XXD is not set +# CONFIG_HWCLOCK is not set +# CONFIG_FEATURE_HWCLOCK_ADJTIME_FHS is not set +# CONFIG_IONICE is not set +# CONFIG_IPCRM is not set +# CONFIG_IPCS is not set +# CONFIG_LAST is not set +# CONFIG_FEATURE_LAST_FANCY is not set +# CONFIG_LOSETUP is not set +# CONFIG_LSPCI is not set +# CONFIG_LSUSB is not set +# CONFIG_MDEV is not set +# CONFIG_FEATURE_MDEV_CONF is not set +# CONFIG_FEATURE_MDEV_RENAME is not set +# CONFIG_FEATURE_MDEV_RENAME_REGEXP is not set +# CONFIG_FEATURE_MDEV_EXEC is not set +# CONFIG_FEATURE_MDEV_LOAD_FIRMWARE is not set +# CONFIG_MESG is not set +# CONFIG_FEATURE_MESG_ENABLE_ONLY_GROUP is not set +# CONFIG_MKE2FS is not set +# CONFIG_MKFS_EXT2 is not set +# CONFIG_MKFS_MINIX is not set +# CONFIG_FEATURE_MINIX2 is not set +# CONFIG_MKFS_REISER is not set +# CONFIG_MKDOSFS is not set +# CONFIG_MKFS_VFAT is not set +# CONFIG_MKSWAP is not set +# CONFIG_FEATURE_MKSWAP_UUID is not set +# CONFIG_MORE is not set +# CONFIG_MOUNT is not set +# CONFIG_FEATURE_MOUNT_FAKE is not set +# CONFIG_FEATURE_MOUNT_VERBOSE is not set +# CONFIG_FEATURE_MOUNT_HELPERS is not set +# CONFIG_FEATURE_MOUNT_LABEL is not set +# CONFIG_FEATURE_MOUNT_NFS is not set +# CONFIG_FEATURE_MOUNT_CIFS is not set +# CONFIG_FEATURE_MOUNT_FLAGS is not set +# CONFIG_FEATURE_MOUNT_FSTAB is not set +# CONFIG_FEATURE_MOUNT_OTHERTAB is not set +# CONFIG_MOUNTPOINT is not set +# CONFIG_NSENTER is not set +# CONFIG_PIVOT_ROOT is not set +# CONFIG_RDATE is not set +# CONFIG_RDEV is not set +# CONFIG_READPROFILE is not set +# CONFIG_RENICE is not set +# CONFIG_REV is not set +# CONFIG_RTCWAKE is not set +# CONFIG_SCRIPT is not set +# CONFIG_SCRIPTREPLAY is not set +# CONFIG_SETARCH is not set +# CONFIG_LINUX32 is not set +# CONFIG_LINUX64 is not set +# CONFIG_SETPRIV is not set +# CONFIG_FEATURE_SETPRIV_DUMP is not set +# CONFIG_FEATURE_SETPRIV_CAPABILITIES is not set +# CONFIG_FEATURE_SETPRIV_CAPABILITY_NAMES is not set +# CONFIG_SETSID is not set +# CONFIG_SWAPON is not set +# CONFIG_FEATURE_SWAPON_DISCARD is not set +# CONFIG_FEATURE_SWAPON_PRI is not set +# CONFIG_SWAPOFF is not set +# CONFIG_FEATURE_SWAPONOFF_LABEL is not set +# CONFIG_SWITCH_ROOT is not set +# CONFIG_TASKSET is not set +# CONFIG_FEATURE_TASKSET_FANCY is not set +# CONFIG_UEVENT is not set +# CONFIG_UMOUNT is not set +# CONFIG_FEATURE_UMOUNT_ALL is not set +# CONFIG_UNSHARE is not set +# CONFIG_WALL is not set +# CONFIG_FEATURE_MOUNT_LOOP is not set +# CONFIG_FEATURE_MOUNT_LOOP_CREATE is not set +# CONFIG_FEATURE_MTAB_SUPPORT is not set +# CONFIG_VOLUMEID is not set +# CONFIG_FEATURE_VOLUMEID_BCACHE is not set +# CONFIG_FEATURE_VOLUMEID_BTRFS is not set +# CONFIG_FEATURE_VOLUMEID_CRAMFS is not set +# CONFIG_FEATURE_VOLUMEID_EXFAT is not set +# CONFIG_FEATURE_VOLUMEID_EXT is not set +# CONFIG_FEATURE_VOLUMEID_F2FS is not set +# CONFIG_FEATURE_VOLUMEID_FAT is not set +# CONFIG_FEATURE_VOLUMEID_HFS is not set +# CONFIG_FEATURE_VOLUMEID_ISO9660 is not set +# CONFIG_FEATURE_VOLUMEID_JFS is not set +# CONFIG_FEATURE_VOLUMEID_LINUXRAID is not set +# CONFIG_FEATURE_VOLUMEID_LINUXSWAP is not set +# CONFIG_FEATURE_VOLUMEID_LUKS is not set +# CONFIG_FEATURE_VOLUMEID_MINIX is not set +# CONFIG_FEATURE_VOLUMEID_NILFS is not set +# CONFIG_FEATURE_VOLUMEID_NTFS is not set +# CONFIG_FEATURE_VOLUMEID_OCFS2 is not set +# CONFIG_FEATURE_VOLUMEID_REISERFS is not set +# CONFIG_FEATURE_VOLUMEID_ROMFS is not set +# CONFIG_FEATURE_VOLUMEID_SQUASHFS is not set +# CONFIG_FEATURE_VOLUMEID_SYSV is not set +# CONFIG_FEATURE_VOLUMEID_UBIFS is not set +# CONFIG_FEATURE_VOLUMEID_UDF is not set +# CONFIG_FEATURE_VOLUMEID_XFS is not set + +# +# Miscellaneous Utilities +# +# CONFIG_ADJTIMEX is not set +# CONFIG_BBCONFIG is not set +# CONFIG_FEATURE_COMPRESS_BBCONFIG is not set +# CONFIG_BEEP is not set +CONFIG_FEATURE_BEEP_FREQ=0 +CONFIG_FEATURE_BEEP_LENGTH_MS=0 +# CONFIG_CHAT is not set +# CONFIG_FEATURE_CHAT_NOFAIL is not set +# CONFIG_FEATURE_CHAT_TTY_HIFI is not set +# CONFIG_FEATURE_CHAT_IMPLICIT_CR is not set +# CONFIG_FEATURE_CHAT_SWALLOW_OPTS is not set +# CONFIG_FEATURE_CHAT_SEND_ESCAPES is not set +# CONFIG_FEATURE_CHAT_VAR_ABORT_LEN is not set +# CONFIG_FEATURE_CHAT_CLR_ABORT is not set +# CONFIG_CONSPY is not set +# CONFIG_CROND is not set +# CONFIG_FEATURE_CROND_D is not set +# CONFIG_FEATURE_CROND_CALL_SENDMAIL is not set +# CONFIG_FEATURE_CROND_SPECIAL_TIMES is not set +CONFIG_FEATURE_CROND_DIR="" +# CONFIG_CRONTAB is not set +# CONFIG_DC is not set +# CONFIG_FEATURE_DC_LIBM is not set +# CONFIG_DEVFSD is not set +# CONFIG_DEVFSD_MODLOAD is not set +# CONFIG_DEVFSD_FG_NP is not set +# CONFIG_DEVFSD_VERBOSE is not set +# CONFIG_FEATURE_DEVFS is not set +# CONFIG_DEVMEM is not set +# CONFIG_FBSPLASH is not set +# CONFIG_FLASH_ERASEALL is not set +# CONFIG_FLASH_LOCK is not set +# CONFIG_FLASH_UNLOCK is not set +# CONFIG_FLASHCP is not set +# CONFIG_HDPARM is not set +# CONFIG_FEATURE_HDPARM_GET_IDENTITY is not set +# CONFIG_FEATURE_HDPARM_HDIO_SCAN_HWIF is not set +# CONFIG_FEATURE_HDPARM_HDIO_UNREGISTER_HWIF is not set +# CONFIG_FEATURE_HDPARM_HDIO_DRIVE_RESET is not set +# CONFIG_FEATURE_HDPARM_HDIO_TRISTATE_HWIF is not set +# CONFIG_FEATURE_HDPARM_HDIO_GETSET_DMA is not set +# CONFIG_HEXEDIT is not set +# CONFIG_I2CGET is not set +# CONFIG_I2CSET is not set +# CONFIG_I2CDUMP is not set +# CONFIG_I2CDETECT is not set +# CONFIG_INOTIFYD is not set +# CONFIG_LESS is not set +CONFIG_FEATURE_LESS_MAXLINES=0 +# CONFIG_FEATURE_LESS_BRACKETS is not set +# CONFIG_FEATURE_LESS_FLAGS is not set +# CONFIG_FEATURE_LESS_TRUNCATE is not set +# CONFIG_FEATURE_LESS_MARKS is not set +# CONFIG_FEATURE_LESS_REGEXP is not set +# CONFIG_FEATURE_LESS_WINCH is not set +# CONFIG_FEATURE_LESS_ASK_TERMINAL is not set +# CONFIG_FEATURE_LESS_DASHCMD is not set +# CONFIG_FEATURE_LESS_LINENUMS is not set +# CONFIG_LSSCSI is not set +# CONFIG_MAKEDEVS is not set +# CONFIG_FEATURE_MAKEDEVS_LEAF is not set +# CONFIG_FEATURE_MAKEDEVS_TABLE is not set +# CONFIG_MAN is not set +# CONFIG_MICROCOM is not set +# CONFIG_MT is not set +# CONFIG_NANDWRITE is not set +# CONFIG_NANDDUMP is not set +# CONFIG_PARTPROBE is not set +# CONFIG_RAIDAUTORUN is not set +CONFIG_READAHEAD=y +# CONFIG_RFKILL is not set +# CONFIG_RUNLEVEL is not set +# CONFIG_RX is not set +# CONFIG_SETFATTR is not set +# CONFIG_SETSERIAL is not set +# CONFIG_STRINGS is not set +# CONFIG_TIME is not set +# CONFIG_TTYSIZE is not set +# CONFIG_UBIATTACH is not set +# CONFIG_UBIDETACH is not set +# CONFIG_UBIMKVOL is not set +# CONFIG_UBIRMVOL is not set +# CONFIG_UBIRSVOL is not set +# CONFIG_UBIUPDATEVOL is not set +# CONFIG_UBIRENAME is not set +# CONFIG_VOLNAME is not set +# CONFIG_WATCHDOG is not set + +# +# Networking Utilities +# +# CONFIG_FEATURE_IPV6 is not set +# CONFIG_FEATURE_UNIX_LOCAL is not set +# CONFIG_FEATURE_PREFER_IPV4_ADDRESS is not set +# CONFIG_VERBOSE_RESOLUTION_ERRORS is not set +# CONFIG_ARP is not set +# CONFIG_ARPING is not set +# CONFIG_BRCTL is not set +# CONFIG_FEATURE_BRCTL_FANCY is not set +# CONFIG_FEATURE_BRCTL_SHOW is not set +CONFIG_DNSD=y +# CONFIG_ETHER_WAKE is not set +CONFIG_FTPD=y +CONFIG_FEATURE_FTPD_WRITE=y +CONFIG_FEATURE_FTPD_ACCEPT_BROKEN_LIST=y +CONFIG_FEATURE_FTPD_AUTHENTICATION=y +CONFIG_FTPGET=y +CONFIG_FTPPUT=y +# CONFIG_FEATURE_FTPGETPUT_LONG_OPTIONS is not set +# CONFIG_HOSTNAME is not set +# CONFIG_DNSDOMAINNAME is not set +CONFIG_HTTPD=y +CONFIG_FEATURE_HTTPD_RANGES=y +CONFIG_FEATURE_HTTPD_SETUID=y +CONFIG_FEATURE_HTTPD_BASIC_AUTH=y +CONFIG_FEATURE_HTTPD_AUTH_MD5=y +CONFIG_FEATURE_HTTPD_CGI=y +CONFIG_FEATURE_HTTPD_CONFIG_WITH_SCRIPT_INTERPR=y +CONFIG_FEATURE_HTTPD_SET_REMOTE_PORT_TO_ENV=y +CONFIG_FEATURE_HTTPD_ENCODE_URL_STR=y +CONFIG_FEATURE_HTTPD_ERROR_PAGES=y +CONFIG_FEATURE_HTTPD_PROXY=y +CONFIG_FEATURE_HTTPD_GZIP=y +# CONFIG_IFCONFIG is not set +# CONFIG_FEATURE_IFCONFIG_STATUS is not set +# CONFIG_FEATURE_IFCONFIG_SLIP is not set +# CONFIG_FEATURE_IFCONFIG_MEMSTART_IOADDR_IRQ is not set +# CONFIG_FEATURE_IFCONFIG_HW is not set +# CONFIG_FEATURE_IFCONFIG_BROADCAST_PLUS is not set +# CONFIG_IFENSLAVE is not set +# CONFIG_IFPLUGD is not set +# CONFIG_IFUP is not set +# CONFIG_IFDOWN is not set +CONFIG_IFUPDOWN_IFSTATE_PATH="" +# CONFIG_FEATURE_IFUPDOWN_IP is not set +# CONFIG_FEATURE_IFUPDOWN_IPV4 is not set +# CONFIG_FEATURE_IFUPDOWN_IPV6 is not set +# CONFIG_FEATURE_IFUPDOWN_MAPPING is not set +# CONFIG_FEATURE_IFUPDOWN_EXTERNAL_DHCP is not set +CONFIG_INETD=y +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_ECHO is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_DISCARD is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_TIME is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_DAYTIME is not set +# CONFIG_FEATURE_INETD_SUPPORT_BUILTIN_CHARGEN is not set +# CONFIG_FEATURE_INETD_RPC is not set +# CONFIG_IP is not set +# CONFIG_IPADDR is not set +# CONFIG_IPLINK is not set +# CONFIG_IPROUTE is not set +# CONFIG_IPTUNNEL is not set +# CONFIG_IPRULE is not set +# CONFIG_IPNEIGH is not set +# CONFIG_FEATURE_IP_ADDRESS is not set +# CONFIG_FEATURE_IP_LINK is not set +# CONFIG_FEATURE_IP_ROUTE is not set +CONFIG_FEATURE_IP_ROUTE_DIR="" +# CONFIG_FEATURE_IP_TUNNEL is not set +# CONFIG_FEATURE_IP_RULE is not set +# CONFIG_FEATURE_IP_NEIGH is not set +# CONFIG_FEATURE_IP_RARE_PROTOCOLS is not set +# CONFIG_IPCALC is not set +# CONFIG_FEATURE_IPCALC_LONG_OPTIONS is not set +# CONFIG_FEATURE_IPCALC_FANCY is not set +CONFIG_FAKEIDENTD=y +# CONFIG_NAMEIF is not set +# CONFIG_FEATURE_NAMEIF_EXTENDED is not set +# CONFIG_NBDCLIENT is not set +# CONFIG_NC is not set +# CONFIG_NETCAT is not set +# CONFIG_NC_SERVER is not set +# CONFIG_NC_EXTRA is not set +# CONFIG_NC_110_COMPAT is not set +# CONFIG_NETSTAT is not set +# CONFIG_FEATURE_NETSTAT_WIDE is not set +# CONFIG_FEATURE_NETSTAT_PRG is not set +# CONFIG_NSLOOKUP is not set +# CONFIG_NTPD is not set +# CONFIG_FEATURE_NTPD_SERVER is not set +# CONFIG_FEATURE_NTPD_CONF is not set +# CONFIG_PING is not set +# CONFIG_PING6 is not set +# CONFIG_FEATURE_FANCY_PING is not set +# CONFIG_PSCAN is not set +# CONFIG_ROUTE is not set +# CONFIG_SLATTACH is not set +# CONFIG_SSL_CLIENT is not set +# CONFIG_TCPSVD is not set +# CONFIG_UDPSVD is not set +CONFIG_TELNET=y +CONFIG_FEATURE_TELNET_TTYPE=y +CONFIG_FEATURE_TELNET_AUTOLOGIN=y +CONFIG_FEATURE_TELNET_WIDTH=y +CONFIG_TELNETD=y +CONFIG_FEATURE_TELNETD_STANDALONE=y +CONFIG_FEATURE_TELNETD_INETD_WAIT=y +CONFIG_TFTP=y +CONFIG_FEATURE_TFTP_PROGRESS_BAR=y +CONFIG_TFTPD=y + +# +# Common options for tftp/tftpd +# +CONFIG_FEATURE_TFTP_GET=y +CONFIG_FEATURE_TFTP_PUT=y +CONFIG_FEATURE_TFTP_BLOCKSIZE=y +# CONFIG_TFTP_DEBUG is not set +# CONFIG_TLS is not set +# CONFIG_TRACEROUTE is not set +# CONFIG_TRACEROUTE6 is not set +# CONFIG_FEATURE_TRACEROUTE_VERBOSE is not set +# CONFIG_FEATURE_TRACEROUTE_USE_ICMP is not set +# CONFIG_TUNCTL is not set +# CONFIG_FEATURE_TUNCTL_UG is not set +# CONFIG_VCONFIG is not set +# CONFIG_WGET is not set +# CONFIG_FEATURE_WGET_LONG_OPTIONS is not set +# CONFIG_FEATURE_WGET_STATUSBAR is not set +# CONFIG_FEATURE_WGET_AUTHENTICATION is not set +# CONFIG_FEATURE_WGET_TIMEOUT is not set +# CONFIG_FEATURE_WGET_HTTPS is not set +# CONFIG_FEATURE_WGET_OPENSSL is not set +# CONFIG_WHOIS is not set +# CONFIG_ZCIP is not set +CONFIG_UDHCPD=y +CONFIG_FEATURE_UDHCPD_BASE_IP_ON_MAC=y +CONFIG_FEATURE_UDHCPD_WRITE_LEASES_EARLY=y +CONFIG_DHCPD_LEASES_FILE="/var/lib/udhcpd/udhcpd.leases" +# CONFIG_DUMPLEASES is not set +# CONFIG_DHCPRELAY is not set +# CONFIG_UDHCPC is not set +# CONFIG_FEATURE_UDHCPC_ARPING is not set +# CONFIG_FEATURE_UDHCPC_SANITIZEOPT is not set +CONFIG_UDHCPC_DEFAULT_SCRIPT="" +# CONFIG_UDHCPC6 is not set +# CONFIG_FEATURE_UDHCPC6_RFC3646 is not set +# CONFIG_FEATURE_UDHCPC6_RFC4704 is not set +# CONFIG_FEATURE_UDHCPC6_RFC4833 is not set + +# +# Common options for DHCP applets +# +# CONFIG_FEATURE_UDHCP_PORT is not set +CONFIG_UDHCP_DEBUG=0 +CONFIG_UDHCPC_SLACK_FOR_BUGGY_SERVERS=80 +CONFIG_FEATURE_UDHCP_RFC3397=y +CONFIG_FEATURE_UDHCP_8021Q=y +CONFIG_IFUPDOWN_UDHCPC_CMD_OPTIONS="" + +# +# Print Utilities +# +# CONFIG_LPD is not set +# CONFIG_LPR is not set +# CONFIG_LPQ is not set + +# +# Mail Utilities +# +# CONFIG_MAKEMIME is not set +# CONFIG_POPMAILDIR is not set +# CONFIG_FEATURE_POPMAILDIR_DELIVERY is not set +# CONFIG_REFORMIME is not set +# CONFIG_FEATURE_REFORMIME_COMPAT is not set +# CONFIG_SENDMAIL is not set +CONFIG_FEATURE_MIME_CHARSET="" + +# +# Process Utilities +# +# CONFIG_FREE is not set +# CONFIG_FUSER is not set +# CONFIG_IOSTAT is not set +# CONFIG_KILL is not set +# CONFIG_KILLALL is not set +# CONFIG_KILLALL5 is not set +# CONFIG_LSOF is not set +# CONFIG_MPSTAT is not set +# CONFIG_NMETER is not set +# CONFIG_PGREP is not set +# CONFIG_PKILL is not set +# CONFIG_PIDOF is not set +# CONFIG_FEATURE_PIDOF_SINGLE is not set +# CONFIG_FEATURE_PIDOF_OMIT is not set +# CONFIG_PMAP is not set +# CONFIG_POWERTOP is not set +# CONFIG_FEATURE_POWERTOP_INTERACTIVE is not set +# CONFIG_PS is not set +# CONFIG_FEATURE_PS_WIDE is not set +# CONFIG_FEATURE_PS_LONG is not set +# CONFIG_FEATURE_PS_TIME is not set +# CONFIG_FEATURE_PS_UNUSUAL_SYSTEMS is not set +# CONFIG_FEATURE_PS_ADDITIONAL_COLUMNS is not set +# CONFIG_PSTREE is not set +# CONFIG_PWDX is not set +# CONFIG_SMEMCAP is not set +# CONFIG_BB_SYSCTL is not set +# CONFIG_TOP is not set +# CONFIG_FEATURE_TOP_INTERACTIVE is not set +# CONFIG_FEATURE_TOP_CPU_USAGE_PERCENTAGE is not set +# CONFIG_FEATURE_TOP_CPU_GLOBAL_PERCENTS is not set +# CONFIG_FEATURE_TOP_SMP_CPU is not set +# CONFIG_FEATURE_TOP_DECIMALS is not set +# CONFIG_FEATURE_TOP_SMP_PROCESS is not set +# CONFIG_FEATURE_TOPMEM is not set +# CONFIG_UPTIME is not set +# CONFIG_FEATURE_UPTIME_UTMP_SUPPORT is not set +# CONFIG_WATCH is not set +# CONFIG_FEATURE_SHOW_THREADS is not set + +# +# Runit Utilities +# +# CONFIG_CHPST is not set +# CONFIG_SETUIDGID is not set +# CONFIG_ENVUIDGID is not set +# CONFIG_ENVDIR is not set +# CONFIG_SOFTLIMIT is not set +# CONFIG_RUNSV is not set +# CONFIG_RUNSVDIR is not set +# CONFIG_FEATURE_RUNSVDIR_LOG is not set +# CONFIG_SV is not set +CONFIG_SV_DEFAULT_SERVICE_DIR="" +# CONFIG_SVC is not set +# CONFIG_SVLOGD is not set +# CONFIG_CHCON is not set +# CONFIG_GETENFORCE is not set +# CONFIG_GETSEBOOL is not set +# CONFIG_LOAD_POLICY is not set +# CONFIG_MATCHPATHCON is not set +# CONFIG_RUNCON is not set +# CONFIG_SELINUXENABLED is not set +# CONFIG_SESTATUS is not set +# CONFIG_SETENFORCE is not set +# CONFIG_SETFILES is not set +# CONFIG_FEATURE_SETFILES_CHECK_OPTION is not set +# CONFIG_RESTORECON is not set +# CONFIG_SETSEBOOL is not set + +# +# Shells +# +# CONFIG_SH_IS_ASH is not set +# CONFIG_SH_IS_HUSH is not set +CONFIG_SH_IS_NONE=y +# CONFIG_BASH_IS_ASH is not set +# CONFIG_BASH_IS_HUSH is not set +CONFIG_BASH_IS_NONE=y +# CONFIG_ASH is not set +# CONFIG_ASH_OPTIMIZE_FOR_SIZE is not set +# CONFIG_ASH_INTERNAL_GLOB is not set +# CONFIG_ASH_BASH_COMPAT is not set +# CONFIG_ASH_JOB_CONTROL is not set +# CONFIG_ASH_ALIAS is not set +# CONFIG_ASH_RANDOM_SUPPORT is not set +# CONFIG_ASH_EXPAND_PRMT is not set +# CONFIG_ASH_IDLE_TIMEOUT is not set +# CONFIG_ASH_MAIL is not set +# CONFIG_ASH_ECHO is not set +# CONFIG_ASH_PRINTF is not set +# CONFIG_ASH_TEST is not set +# CONFIG_ASH_HELP is not set +# CONFIG_ASH_GETOPTS is not set +# CONFIG_ASH_CMDCMD is not set +# CONFIG_ASH_BASH_SOURCE_CURDIR is not set +# CONFIG_ASH_COMMAND_NOT_FOUND_HOOK is not set +# CONFIG_CTTYHACK is not set +# CONFIG_HUSH is not set +# CONFIG_HUSH_BASH_COMPAT is not set +# CONFIG_HUSH_BRACE_EXPANSION is not set +# CONFIG_HUSH_INTERACTIVE is not set +# CONFIG_HUSH_SAVEHISTORY is not set +# CONFIG_HUSH_JOB is not set +# CONFIG_HUSH_TICK is not set +# CONFIG_HUSH_IF is not set +# CONFIG_HUSH_LOOPS is not set +# CONFIG_HUSH_CASE is not set +# CONFIG_HUSH_FUNCTIONS is not set +# CONFIG_HUSH_LOCAL is not set +# CONFIG_HUSH_RANDOM_SUPPORT is not set +# CONFIG_HUSH_MODE_X is not set +# CONFIG_HUSH_ECHO is not set +# CONFIG_HUSH_PRINTF is not set +# CONFIG_HUSH_TEST is not set +# CONFIG_HUSH_HELP is not set +# CONFIG_HUSH_EXPORT is not set +# CONFIG_HUSH_EXPORT_N is not set +# CONFIG_HUSH_READONLY is not set +# CONFIG_HUSH_KILL is not set +# CONFIG_HUSH_WAIT is not set +# CONFIG_HUSH_TRAP is not set +# CONFIG_HUSH_TYPE is not set +# CONFIG_HUSH_TIMES is not set +# CONFIG_HUSH_READ is not set +# CONFIG_HUSH_SET is not set +# CONFIG_HUSH_UNSET is not set +# CONFIG_HUSH_ULIMIT is not set +# CONFIG_HUSH_UMASK is not set +# CONFIG_HUSH_GETOPTS is not set +# CONFIG_HUSH_MEMLEAK is not set + +# +# Options common to all shells +# +# CONFIG_FEATURE_SH_MATH is not set +# CONFIG_FEATURE_SH_MATH_64 is not set +# CONFIG_FEATURE_SH_EXTRA_QUIET is not set +# CONFIG_FEATURE_SH_STANDALONE is not set +# CONFIG_FEATURE_SH_NOFORK is not set +# CONFIG_FEATURE_SH_READ_FRAC is not set +# CONFIG_FEATURE_SH_HISTFILESIZE is not set + +# +# System Logging Utilities +# +# CONFIG_KLOGD is not set +# CONFIG_FEATURE_KLOGD_KLOGCTL is not set +# CONFIG_LOGGER is not set +# CONFIG_LOGREAD is not set +# CONFIG_FEATURE_LOGREAD_REDUCED_LOCKING is not set +# CONFIG_SYSLOGD is not set +# CONFIG_FEATURE_ROTATE_LOGFILE is not set +# CONFIG_FEATURE_REMOTE_LOG is not set +# CONFIG_FEATURE_SYSLOGD_DUP is not set +# CONFIG_FEATURE_SYSLOGD_CFG is not set +CONFIG_FEATURE_SYSLOGD_READ_BUFFER_SIZE=0 +# CONFIG_FEATURE_IPC_SYSLOG is not set +CONFIG_FEATURE_IPC_SYSLOG_BUFFER_SIZE=0 +# CONFIG_FEATURE_KMSG_SYSLOG is not set diff --git a/legacy/busybox/dad.if-up b/legacy/busybox/dad.if-up new file mode 100644 index 000000000..e76bb60bf --- /dev/null +++ b/legacy/busybox/dad.if-up @@ -0,0 +1,8 @@ +#!/bin/sh + +# Block ifup until DAD completion +# Copyright (c) 2016 Kaarle Ritvanen + +while ip address show dev $IFACE | grep -q " tentative "; do + sleep 0.2 +done diff --git a/legacy/busybox/external_ssl_client.patch b/legacy/busybox/external_ssl_client.patch new file mode 100644 index 000000000..8adb7b41b --- /dev/null +++ b/legacy/busybox/external_ssl_client.patch @@ -0,0 +1,52 @@ +diff --git a/networking/wget.c b/networking/wget.c +index cd92b3a28..a12c921cd 100644 +--- a/networking/wget.c ++++ b/networking/wget.c +@@ -50,7 +50,6 @@ + //config: bool "Support HTTPS using internal TLS code" + //config: default y + //config: depends on WGET +-//config: select TLS + //config: help + //config: wget will use internal TLS code to connect to https:// URLs. + //config: Note: +@@ -767,8 +766,8 @@ static void spawn_ssl_client(const char *host, int network_fd) + int pid; + char *servername, *p; + +- if (!(option_mask32 & WGET_OPT_NO_CHECK_CERT)) +- bb_error_msg("note: TLS certificate validation not implemented"); ++ if (ENABLE_SSL_CLIENT && !(option_mask32 & WGET_OPT_NO_CHECK_CERT)) ++ bb_error_msg_and_die("note: TLS certificate validation not implemented"); + + servername = xstrdup(host); + p = strrchr(servername, ':'); +@@ -785,21 +784,25 @@ static void spawn_ssl_client(const char *host, int network_fd) + close(sp[0]); + xmove_fd(sp[1], 0); + xdup2(0, 1); +- if (BB_MMU) { ++ if (BB_MMU && ENABLE_TLS && (option_mask32 & WGET_OPT_NO_CHECK_CERT)) { + tls_state_t *tls = new_tls_state(); + tls->ifd = tls->ofd = network_fd; + tls_handshake(tls, servername); + tls_run_copy_loop(tls); + exit(0); + } else { +- char *argv[5]; ++ char *argv[6]; + xmove_fd(network_fd, 3); + argv[0] = (char*)"ssl_client"; + argv[1] = (char*)"-s3"; + //TODO: if (!is_ip_address(servername))... + argv[2] = (char*)"-n"; + argv[3] = servername; +- argv[4] = NULL; ++ if (!ENABLE_SSL_CLIENT &&(option_mask32 & WGET_OPT_NO_CHECK_CERT)) { ++ argv[4] = (char*)"-I"; ++ argv[5] = NULL; ++ } else ++ argv[4] = NULL; + BB_EXECVP(argv[0], argv); + bb_perror_msg_and_die("can't execute '%s'", argv[0]); + } diff --git a/legacy/busybox/nologin.c b/legacy/busybox/nologin.c new file mode 100644 index 000000000..75ad89eda --- /dev/null +++ b/legacy/busybox/nologin.c @@ -0,0 +1,38 @@ +/* vi: set sw=4 ts=4: */ +/* + * nologin implementation for busybox + * + * Licensed under GPLv2 or later, see file LICENSE in this source tree. + */ + +//config:config NOLOGIN +//config: bool "nologin" +//config: default n +//config: help +//config: nologin is a tool that is supposed to be the shell for user accounts +//config: that are not supposed to login. + +//applet:IF_NOLOGIN(APPLET(nologin, BB_DIR_SBIN, BB_SUID_DROP)) +//kbuild:lib-$(CONFIG_NOLOGIN) += nologin.o + +//usage:#define nologin_trivial_usage +//usage: "" +//usage:#define nologin_full_usage "\n\n" +//usage: "politely refuse a login\n" + +#include "libbb.h" +#include <syslog.h> + +#define _NOLOGIN_TXT "/etc/nologin.txt" + +int nologin_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; +int nologin_main(int argc UNUSED_PARAM, char **argv UNUSED_PARAM) +{ + int fd; + fd = open(_NOLOGIN_TXT, O_RDONLY); + if (bb_copyfd_eof(fd, STDOUT_FILENO) == -1) + bb_error_msg_and_die("this account is not available"); + close(fd); + return 1; +} + diff --git a/legacy/busybox/ssl_client.c b/legacy/busybox/ssl_client.c new file mode 100644 index 000000000..8aa558e70 --- /dev/null +++ b/legacy/busybox/ssl_client.c @@ -0,0 +1,158 @@ +#include <err.h> +#include <errno.h> +#include <poll.h> +#include <stdio.h> +#include <stdlib.h> +#include <unistd.h> + +#include <tls.h> + +#define BUFSIZE 16384 + +#define TLS_DEBUG 0 + +#if TLS_DEBUG +# define dbg(...) fprintf(stderr, __VA_ARGS__) +#else +# define dbg(...) ((void)0) +#endif + +static void copy_from_stdin_to_tls(struct tls *ctx, int *fd) +{ + static size_t buf[BUFSIZE]; + ssize_t n; + int i = 0; + dbg("DEBUG: data from STDIN\n"); + do { + n = read(STDIN_FILENO, buf, sizeof(buf)); + dbg("read %zu\n", n); + } while (n < 0 && errno == EINTR); + + if (n < 1) { + *fd = -1; + return; + } + + while (n > 0) { + ssize_t r = tls_write(ctx, &buf[i], n); + if (r == TLS_WANT_POLLIN || r == TLS_WANT_POLLOUT) + continue; + if (r < 0) + err(1, "tls_write: %s", tls_error(ctx)); + i += r; + n -= r; + } +} + +static int copy_from_tls_to_stdout(struct tls *ctx) +{ + static size_t buf[BUFSIZE]; + ssize_t n,r; + int i = 0; + + dbg("DEBUG: data from TLS\n"); + do { + n = tls_read(ctx, buf, sizeof(buf)); + } while (n == TLS_WANT_POLLIN || r == TLS_WANT_POLLOUT); + if (n < 0) + err(1, "tls read: %s", tls_error(ctx)); + + if (n == 0) + return 1; + + while (n) { + r = write(STDOUT_FILENO, &buf[i], n); + if (r < 0) + err(1, "write"); + i += r; + n -= r; + } + return 0; +} + +int do_poll(struct pollfd *fds, int nfds) +{ + int r; + while ((r = poll(fds, nfds, -1)) < 0) { + if (errno != EINTR && errno != ENOMEM) + err(1, "poll"); + } + return r; +} + +static void copy_loop(struct tls *ctx, int sfd) +{ + struct pollfd fds[2] = { + { .fd = STDIN_FILENO, .events = POLLIN }, + { .fd = sfd, .events = POLLIN }, + }; + + while (1) { + int r = do_poll(fds, 2); + if (fds[0].revents) + copy_from_stdin_to_tls(ctx, &fds[0].fd); + + if (fds[1].revents && copy_from_tls_to_stdout(ctx)) + break; + } +} + +void usage(const char *prog, int ret) { + printf("usage: %s [-s FD] [-I] -n SNI\n", prog); + exit(ret); +} + +int main(int argc, char *argv[]) +{ + int c, sfd = 1;; + const char *sni = NULL; + struct tls_config *tc; + struct tls *ctx; + int insecure = 0; + + while ((c = getopt(argc, argv, "hs:n:I")) != -1) { + switch (c) { + case 'h': + usage(argv[0], 0); + break; + case 's': + sfd = atoi(optarg); + break; + case 'n': + sni = optarg; + break; + case 'I': + insecure = 1; + break; + case '?': + usage(argv[0], 1); + } + } + + if (tls_init() == -1) + errx(1, "tls_init() failed"); + + if ((ctx = tls_client()) == NULL) + errx(1, "tls_client() failed"); + + if (insecure) { + if ((tc = tls_config_new()) == NULL) + errx(1, "tls_config_new() failed"); + tls_config_insecure_noverifycert(tc); + tls_config_insecure_noverifyname(tc); + tls_config_insecure_noverifytime(tc); + if (tls_configure(ctx, tc) == -1) + err(1, "tls_configure: %s", tls_error(ctx)); + tls_config_free(tc); + } + + if (tls_connect_fds(ctx, sfd, sfd, sni) == -1) + errx(1, "%s: TLS connect failed", sni); + + if (tls_handshake(ctx) == -1) + errx(1, "%s: %s", sni, tls_error(ctx)); + + copy_loop(ctx, sfd); + tls_close(ctx); + return 0; +} diff --git a/legacy/busybox/top-buffer-overflow.patch b/legacy/busybox/top-buffer-overflow.patch new file mode 100644 index 000000000..14b23c648 --- /dev/null +++ b/legacy/busybox/top-buffer-overflow.patch @@ -0,0 +1,20 @@ +--- busybox-1.27.0.orig/procps/top.c ++++ busybox-1.27.0/procps/top.c +@@ -694,10 +694,14 @@ + CALC_STAT(pcpu, (s->pcpu*pcpu_scale + pcpu_half) >> pcpu_shift); + #endif + +- if (s->vsz >= 100000) +- sprintf(vsz_str_buf, "%6ldm", s->vsz/1024); ++ if ((s->vsz / (1024 * 1024)) >= 100000) ++ snprintf(vsz_str_buf, sizeof(vsz_str_buf), "%6ldt", s->vsz/(1024 * 1024 * 1024)); ++ else if ((s->vsz / 1024) >= 100000) ++ snprintf(vsz_str_buf, sizeof(vsz_str_buf), "%6ldg", s->vsz/(1024 * 1024)); ++ else if (s->vsz >= 100000) ++ snprintf(vsz_str_buf, sizeof(vsz_str_buf), "%6ldm", s->vsz/1024); + else +- sprintf(vsz_str_buf, "%7lu", s->vsz); ++ snprintf(vsz_str_buf, sizeof(vsz_str_buf), "%7lu", s->vsz); + /* PID PPID USER STAT VSZ %VSZ [%CPU] COMMAND */ + col = snprintf(line_buf, scr_width, + "\n" "%5u%6u %-8.8s %s%s" FMT |