Differences from the last version of this patchset: - Improved overall code quality - Removed dependency on non-POSIX execvpe function - Short-wired get_shell_name() when feature is enabled - Fixed multiple compilation warnings
Previous version of this patchset: https://lists.busybox.net/pipermail/busybox/2025-April/091441.html Nadav Tasher (17): libbb: mask xvfork to xfork on MMU targets libbb: implement clone_string_array libbb: implement close_cloexec_fds libbb: implement reset_all_signals libbb: implement bb_execXX function family to handle applet executions libbb: make spawn and spawn_and_wait use bb_execvp libbb: implement bb_system using spawn_and_wait applets: change system() calls to bb_system() get_shell_name: Use "sh" as shell name when FEATURE_PREFER_APPLETS is enabled libbb: make bb_system use get_shell_name to find shell ash: use bb_execve to execute commands and applets in tryexec hush: use bb_execvp to execute commands and applets in execvp_or_die tar: replace execlp call with bb_execvp, disable xz compression support when FEATURE_PREFER_APPLETS is enabled applets: use bb_execXX functions instead of direct exec calls httpd: replace execv call with bb_execv and disable FEATURE_HTTPD_CGI when FEATURE_PREFER_APPLETS is enabled libbb: allow forcing all applets to behave as NOEXEC applets libbb: implement re_exec using bb_execv Config.in | 33 +++++ archival/dpkg.c | 2 +- archival/libarchive/data_extract_to_command.c | 14 ++- archival/libarchive/open_transformer.c | 3 +- archival/tar.c | 28 ++++- console-tools/openvt.c | 2 +- console-tools/reset.c | 2 +- coreutils/chroot.c | 2 +- coreutils/env.c | 2 +- coreutils/nice.c | 2 +- coreutils/nohup.c | 2 +- coreutils/timeout.c | 2 +- debianutils/start_stop_daemon.c | 2 +- docs/nofork_noexec.txt | 17 ++- editors/awk.c | 2 +- editors/vi.c | 2 +- include/busybox.h | 6 +- include/libbb.h | 55 +++++--- init/bootchartd.c | 21 +++- init/halt.c | 9 +- init/init.c | 4 +- libbb/Kbuild.src | 1 + libbb/clone_string_array.c | 29 +++++ libbb/executable.c | 117 ++++++++++++++++-- libbb/get_shell_name.c | 6 + libbb/run_shell.c | 4 +- libbb/signals.c | 26 ++++ libbb/vfork_daemon_rexec.c | 74 ++++++++--- libbb/xfuncs.c | 10 ++ loginutils/adduser.c | 7 +- loginutils/getty.c | 19 ++- mailutils/mail.c | 2 +- mailutils/reformime.c | 2 +- miscutils/conspy.c | 11 +- miscutils/crond.c | 38 +++++- miscutils/crontab.c | 13 +- miscutils/man.c | 2 +- miscutils/time.c | 2 +- networking/ftpd.c | 3 +- networking/httpd.c | 14 ++- networking/ifupdown.c | 17 ++- networking/inetd.c | 6 +- networking/nc.c | 3 +- networking/nc_bloaty.c | 2 +- networking/slattach.c | 2 +- networking/tcpudp.c | 2 +- networking/telnetd.c | 2 +- networking/wget.c | 5 +- printutils/lpd.c | 2 +- procps/watch.c | 2 +- runit/chpst.c | 2 +- runit/runsv.c | 9 +- runit/runsvdir.c | 13 +- runit/svlogd.c | 15 ++- selinux/runcon.c | 2 +- shell/ash.c | 72 ++++------- shell/cttyhack.c | 2 +- shell/hush.c | 76 +----------- util-linux/chrt.c | 2 +- util-linux/ionice.c | 2 +- util-linux/mdev.c | 2 +- util-linux/script.c | 18 ++- util-linux/setarch.c | 2 +- util-linux/setpriv.c | 2 +- util-linux/setsid.c | 2 +- util-linux/switch_root.c | 2 +- util-linux/taskset.c | 2 +- 67 files changed, 596 insertions(+), 264 deletions(-) create mode 100644 libbb/clone_string_array.c -- 2.34.1 _______________________________________________ busybox mailing list busybox@busybox.net https://lists.busybox.net/mailman/listinfo/busybox