aboutsummaryrefslogtreecommitdiff
path: root/include (follow)
Commit message (Collapse)AuthorAgeFilesLines
* win32: add FAST_FUNC annotationsRon Yorston2026-05-041-111/+111
| | | | | | | | | I've been far too lax in applying FAST_FUNC annotations. These can make function calls smaller and faster, but only on 32-bit systems and for non-static, non-variadic functions with non-void arguments. Saves 4680 bytes in the 32-bit build; 64-bit builds are unaffected.
* crond: build tweaksRon Yorston2026-05-031-1/+1
| | | | | | | | | | | | | | | Using 'depends on FEATURE_SYSLOG' is unreliable because FEATURE_SYSLOG can't be set directly. A POSIX build with all applets that need syslog disabled *except* crond may fail. Revert to using 'select FEATURE_SYSLOG' in crond and exclude the unused syslog code on Windows. If crond is unable to run sendmail report this in the error message. Update all default Windows configurations. (GitHub PR #561)
* win32: improve urandom/zero device handlingRon Yorston2026-04-261-0/+1
| | | | | | Rearrange the code to avoid a superfluous process creation. Saves 16 bytes in the 64-bit build, adds 24 in the 32-bit.
* wget: allow HTTPS certificate check to be skippedRon Yorston2026-04-241-0/+2
| | | | | | | | | | | The Microsoft Windows Schannel implementation of TLS validates the server certificate. Enable the --no-check-certificate option to wget to allow these checks to be skipped. This may be useful to connect to badly configured websites. Adds 202 bytes to the x86_64 build with Schannel enabled. (GitHub issue #581)
* ash: allow 'times' built-in to report process timingRon Yorston2026-04-122-3/+6
| | | | | | | | | | | | | | Move existing code which obtains process execution times into a separate function. Use it to allow times(2) to report execution times for the current process, though not child execution times. Change TICKS_PER_SECOND from 100 to 1000 to increase the displayed resolution of process times (though the measured resolution may well be less than this). Adds 48-80 bytes. (GitHub issue #574)
* Merge branch 'busybox' into mergeRon Yorston2026-03-111-27/+104
|\
| * *: don't use getservbyname, it links in a static bufferDenys Vlasenko2026-02-251-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta bb_get_servport_by_name - 348 +348 bb_lookup_port 83 111 +28 reread_config_file 886 907 +21 static.se 16 - -16 getservbyname 53 - -53 getservbyname_r 284 - -284 ------------------------------------------------------------------------------ (add/remove: 2/5 grow/shrink: 2/0 up/down: 397/-353) Total: 44 bytes text data bss dec hex filename 1080084 555 5024 1085663 1090df busybox_old 1080144 555 4992 1085691 1090fb busybox_unstripped Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * netstat: fix breakage due to last commitDenys Vlasenko2026-02-241-1/+1
| | | | | | | | | | | | | | | | | | | | function old new delta bb_get_servname_by_port 182 195 +13 ip_port_str 121 120 -1 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/1 up/down: 13/-1) Total: 12 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * netstat,pscan: don't use getservbyport(), it links in a static bufferDenys Vlasenko2026-02-241-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta bb_get_servname_by_port - 182 +182 ip_port_str 112 121 +9 pscan_main 594 591 -3 getservbyport 53 - -53 getservbyport_r 430 - -430 ------------------------------------------------------------------------------ (add/remove: 2/4 grow/shrink: 1/1 up/down: 191/-486) Total: -295 bytes text data bss dec hex filename 1080362 555 5056 1085973 109215 busybox_old 1080067 555 5024 1085646 1090ce busybox_unstripped Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * telnet: rewrite to use ioloop()Denys Vlasenko2026-02-231-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Now should never block on network I/O. Also, window resizing is dynamic now. function old new delta write_to_net - 596 +596 read_from_net - 543 +543 read_from_stdin - 227 +227 show_menu - 212 +212 write_to_stdout - 105 +105 have_data_to_write_to_net - 72 +72 have_data_to_write_to_stdout - 38 +38 put_iac_byte_escaped - 32 +32 ioloop_run 411 438 +27 have_buffer_to_read_from_stdin - 25 +25 have_buffer_to_read_from_net - 25 +25 .rodata 107125 107141 +16 handle_SIGWINCH - 15 +15 put_iac 36 28 -8 put_iac4_msb_lsb 19 - -19 iac_flush 36 - -36 setConMode 87 - -87 handle_net_output 110 - -110 con_escape 271 - -271 telnet_main 1232 476 -756 ------------------------------------------------------------------------------ (add/remove: 11/5 grow/shrink: 2/2 up/down: 1933/-1287) Total: 646 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * libbb: add generic "fd polling and I/O" loop, use it in telnetdDenys Vlasenko2026-02-211-13/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We do it, badly, in many places. Better to use one robust implementation. Can be buggy yet. Initial use is in a rather old, rarely used tech: telnet. The I/O in telnetd should be fully non-blocking now, including pty delays handling. Several bugs in telnetd handling of IACs are fixed. function old new delta ioloop_run - 411 +411 net_to_pty__have_data_to_write - 368 +368 pty_to_net__write - 318 +318 net_to_pty__write - 180 +180 pty_to_net__read - 171 +171 net_to_pty__have_buffer_to_read_into - 164 +164 pty_to_net__have_buffer_to_read_into - 90 +90 net_to_pty__read - 87 +87 pty_to_net__have_data_to_write - 59 +59 make_new_session 491 550 +59 conn_close_fds - 52 +52 accept_conn__accept - 49 +49 conn_close_fds_remove_and_free - 27 +27 ioloop_remove_conn - 22 +22 remove_and_free_to_pty - 19 +19 ioloop_insert_conn - 10 +10 accept_conn__can_accept - 6 +6 accept_conn__return_zero - 3 +3 static.ayt_response - 2 +2 handle_sigchld 59 61 +2 free_session 130 - -130 telnetd_main 1797 367 -1430 ------------------------------------------------------------------------------ (add/remove: 19/1 grow/shrink: 2/1 up/down: 2099/-1560) Total: 539 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * tls: server: fix incorrect key_block assignments - now works against openssl ↵Denys Vlasenko2026-02-151-11/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | s_client function old new delta privRsaEncryptSignedElement - 236 +236 tls_handshake_as_server 2033 2264 +231 .rodata 108079 108301 +222 initialize_aes_keys - 77 +77 xwrite_encrypted 507 506 -1 tls_handshake 1519 1500 -19 derive_master_secret_and_keys 154 123 -31 ------------------------------------------------------------------------------ (add/remove: 2/0 grow/shrink: 2/3 up/down: 766/-51) Total: 715 bytes Totoal growth compared to code before TLS server code: function old new delta tls_handshake_as_server - 2264 +2264 .rodata 107074 108301 +1227 psRsaCrypt - 577 +577 load_rsa_priv_key - 282 +282 ssl_server_main - 279 +279 privRsaEncryptSignedElement - 236 +236 ssl_client_main 137 363 +226 psRsaDecryptPriv - 171 +171 set_cipher_parameters - 161 +161 derive_master_secret_and_keys - 123 +123 packed_usage 36034 36146 +112 sp_ecc_make_key_256 - 103 +103 send_finished - 94 +94 get_change_cipher_spec - 88 +88 initialize_aes_keys - 77 +77 static.BLOCK_NAMES - 70 +70 curve_P256_compute_premaster - 65 +65 der_binary_to_pstm - 50 +50 curve_x25519_generate_keypair - 44 +44 get_finished - 42 +42 get_outbuf_fill_handshake_record - 37 +37 client_hello_ciphers - 32 +32 curve_P256_generate_keypair - 27 +27 sp_256_from_bin_8 - 26 +26 tls_xread_record 681 704 +23 curve_x25519_compute_premaster - 15 +15 applet_names 2870 2881 +11 applet_main 1652 1656 +4 xwrite_encrypted 507 506 -1 xwrite_and_update_handshake_hash 76 59 -17 sp_256_point_from_bin2x32 70 43 -27 curve_x25519_compute_pubkey_and_premaster 71 39 -32 curve_P256_compute_pubkey_and_premaster 167 65 -102 psRsaEncryptPub 395 199 -196 tls_handshake 2069 1500 -569 ------------------------------------------------------------------------------ (add/remove: 23/0 grow/shrink: 6/7 up/down: 6466/-944) Total: 5522 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * tls: fix cipher-id selection in server modeDenys Vlasenko2026-02-151-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ECDSA keys still don't work, and currently will be ignored function old new delta tls_handshake_as_server 824 1601 +777 .rodata 107764 108007 +243 set_cipher_parameters - 161 +161 packed_usage 36072 36146 +74 static.BLOCK_NAMES - 70 +70 client_hello_ciphers - 32 +32 ssl_server_main 288 279 -9 load_rsa_priv_key 329 282 -47 tls_handshake 1676 1530 -146 ------------------------------------------------------------------------------ (add/remove: 3/0 grow/shrink: 3/3 up/down: 1357/-202) Total: 1155 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * tls: implement server codeDenys Vlasenko2026-02-151-3/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta tls_handshake_as_server 7 852 +845 .rodata 107103 107764 +661 psRsaCrypt - 577 +577 load_rsa_priv_key - 329 +329 psRsaDecryptPriv - 200 +200 derive_master_secret_and_keys - 154 +154 send_finished - 95 +95 get_change_cipher_spec - 88 +88 der_binary_to_pstm - 50 +50 get_finished - 42 +42 tls_xread_record 681 708 +27 ssl_server_main 285 288 +3 psRsaEncryptPub 395 199 -196 tls_handshake 2069 1690 -379 ------------------------------------------------------------------------------ (add/remove: 8/0 grow/shrink: 4/2 up/down: 3071/-575) Total: 2496 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * ssl_server: new applet, not functional yetDenys Vlasenko2026-02-151-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta ssl_server_main - 285 +285 ssl_client_main 137 363 +226 packed_usage 36034 36072 +38 .rodata 107074 107103 +29 applet_names 2870 2881 +11 tls_handshake_as_server - 7 +7 applet_main 1652 1656 +4 ------------------------------------------------------------------------------ (add/remove: 3/0 grow/shrink: 5/0 up/down: 600/0) Total: 600 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | ash: allow execution of busybox-w32 binary without extensionRon Yorston2026-02-251-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the busybox-w32 binary didn't have an extension the shell was unable to spawn itself: $ ls -l busybox -rwxrwxr-x 1 rmy rmy 661006 Feb 25 09:37 busybox $ ./busybox sh $ ls sh: unable to spawn shell This happened because the shell used spawnve() from the C runtime to execute itself. Microsoft insists on trying to add an extension to the name of the binary unless it has an explicit '.' as its last character. Use the internal spawnveq() instead, as it handles various quirks like the above. Adds 16-32 bytes. (GitHub issue #566)
* | Merge branch 'busybox' into mergeRon Yorston2026-02-121-1/+10
|\|
| * vi: fix "s /find/repl" with whitespace before /Denys Vlasenko2026-02-061-0/+2
| | | | | | | | | | | | | | function old new delta colon 3977 4005 +28 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * libbb: introduce and use xasprintf_inplace()Denys Vlasenko2026-02-051-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta xasprintf_and_free - 49 +49 watch_main 269 282 +13 singlemount 1313 1315 +2 append_mount_options 157 149 -8 ip_port_str 122 112 -10 lsblk_main 869 858 -11 add_cmd 1178 1167 -11 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 2/4 up/down: 64/-40) Total: 24 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * libbb: use narrow isqrt() when 64-bit one is not needed (only "factor" uses it)Denys Vlasenko2026-02-041-1/+6
| | | | | | | | | | | | | | | | | | | | | | function old new delta isqrt_ull - 84 +84 create_J 1809 1808 -1 isqrt 106 38 -68 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 0/2 up/down: 84/-69) Total: 15 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | Merge branch 'busybox' into mergeRon Yorston2026-02-102-1/+3
|\|
| * uuidgen: move UUID formatting to libbbDenys Vlasenko2026-02-031-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta format_uuid_DCE_37_chars - 94 +94 uuidgen_main 71 53 -18 .rodata 107089 107066 -23 mkswap_main 278 253 -25 volume_id_set_uuid 258 178 -80 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 0/4 up/down: 94/-146) Total: -52 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * tar: strip unsafe hardlink components - GNU tar does the sameDenys Vlasenko2026-01-291-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Defends against files like these (python reproducer): import tarfile ti = tarfile.TarInfo("leak_hosts") ti.type = tarfile.LNKTYPE ti.linkname = "/etc/hosts" # or "../etc/hosts" or ".." ti.size = 0 with tarfile.open("/tmp/hardlink.tar", "w") as t: t.addfile(ti) function old new delta skip_unsafe_prefix - 127 +127 get_header_tar 1752 1754 +2 .rodata 106861 106856 -5 unzip_main 2715 2706 -9 strip_unsafe_prefix 102 18 -84 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 1/3 up/down: 129/-98) Total: 31 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | win32: add support for /dev/std{in,out,err}Ron Yorston2026-02-021-2/+6
| | | | | | | | | | | | | | Allow applets to open the "files" /dev/stdin, /dev/stdout and /dev/stderr. The 'stat' and 'ls' applets pretend they exist. Adds 48-56 bytes.
* | Merge branch 'busybox' into mergeRon Yorston2026-02-022-0/+17
|\|
| * httpd: code shrink via "split-globals" trickDenys Vlasenko2026-01-241-0/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta httpd_main 957 968 +11 log_and_exit 25 26 +1 send_headers 712 708 -4 handle_incoming_and_exit 2292 2285 -7 sigalrm_handler 102 93 -9 parse_conf 1332 1323 -9 send_cgi_and_exit 803 790 -13 cgi_io_loop_and_exit 656 635 -21 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 2/6 up/down: 12/-63) Total: -51 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * httpd: simplify CGI headers handling, check "HTTP/1.1" prefix, not just "HTTP"Denys Vlasenko2026-01-231-0/+2
| | | | | | | | | | | | | | | | | | | | function old new delta cgi_io_loop_and_exit 477 498 +21 .rodata 106830 106821 -9 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/1 up/down: 21/-9) Total: 12 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | libbb: refactor CNG hashing implementationrfl8902026-01-271-21/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The existing CNG implementation relied on multiple features only implemented in "newer" Windows versions. This new implementation does not use the aforementioned features and is therefore compatible with systems running Windows Vista or higher. function old new delta .rdata 87112 87288 +176 hmac_peek_hash 80 208 +128 get_alg_handle - 96 +96 algorithm_provider_hmac_cache - 48 +48 algorithm_provider_cache - 48 +48 alg_id_mappings - 48 +48 sha512_begin 16 48 +32 sha384_begin 16 48 +32 sha256_begin 16 48 +32 sha1_begin 16 48 +32 md5_begin 16 32 +16 hmac_hash_v 48 64 +16 hmac_end 48 64 +16 hmac_blocks.constprop.0 96 112 +16 __imp_BCryptOpenAlgorithmProvider - 8 +8 __imp_BCryptDuplicateHash - 8 +8 BCryptOpenAlgorithmProvider - 8 +8 BCryptDuplicateHash - 8 +8 ------------------------------------------------------------------------------ (add/remove: 8/0 grow/shrink: 10/0 up/down: 768/0) Total: 768 bytes
* | win32: mkdtemp is available in mingw-w64 14.0.0Ron Yorston2026-01-191-0/+2
| | | | | | | | | | | | | | | | mingw-w64 has introduced an implementation of mkdtemp() for its 14.0.0 release. Use this in preference to the internal code, where available. (GitHub issue #555)
* | win32: avoid failure when localtime() argument is out of rangeRon Yorston2025-11-261-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The implementation of localtime(3) in the Microsoft Windows runtime only accepts arguments between the Unix epoch (1970) and either 2038 or 3000 for 32-bit or 64-bit systems respectively. For values outside those limits it returns a NULL pointer. Unfortunately, upstream BusyBox hardly ever bothers to check the return value. Thus, when a call to stat(2) returned an all-zero FILETIME for a file, the 'stat' applet failed. An all-zero FILETIME represents a date in 1600, which is clearly before the Unix epoch. Add a wrapper to localtime(3) which detects an out-of-range value and returns a valid 'struct tm' for the Unix epoch. This is easier than adding checks on the return value of every call to localtime(3). Adds 32-48 bytes. (GitHub issue #548)
* | Merge branch 'busybox' into mergeRon Yorston2025-11-111-0/+4
|\|
| * dd: fix overflow for very large count/seek/skip valuesDenys Vlasenko2025-11-081-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | function old new delta xatoull_range_sfx - 49 +49 dd_main 1607 1640 +33 bb_banner 47 46 -1 ------------------------------------------------------------------------------ (add/remove: 1/0 grow/shrink: 1/1 up/down: 82/-1) Total: 81 bytes Signed-off-by: Sertonix <sertonix@posteo.net> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * ash: eval: Add vfork supportDenys Vlasenko2025-08-091-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Upstream commit: Date: Sat, 19 May 2018 02:39:56 +0800 eval: Add vfork support This patch adds basic vfork support for the case of a simple command. Upstream commit: Date: Tue, 12 Jan 2021 17:11:19 +1100 jobs: Always reset SIGINT/SIGQUIT handlers On Fri, Jan 08, 2021 at 08:55:41PM +0000, Harald van Dijk wrote: > On 18/05/2018 19:39, Herbert Xu wrote: > > This patch adds basic vfork support for the case of a simple command. > > ... @@ -879,17 +892,30 @@ forkchild(struct job *jp, union node *n, int > > mode) > > } > > } > > if (!oldlvl && iflag) { > > - setsignal(SIGINT); > > - setsignal(SIGQUIT); > > + if (mode != FORK_BG) { > > + setsignal(SIGINT); > > + setsignal(SIGQUIT); > > + } > > setsignal(SIGTERM); > > } > > + > > + if (lvforked) > > + return; > > + > > for (jp = curjob; jp; jp = jp->prev_job) > > freejob(jp); > > } > > This leaves SIGQUIT ignored in background jobs in interactive shells. > > ENV= dash -ic 'dash -c "kill -QUIT \$\$; echo huh" & wait' > > As of dash 0.5.11, this prints "huh". Before, the subprocess process killed > itself before it could print anything. Other shells do not leave SIGQUIT > ignored. > > (In a few other shells, this also prints "huh", but in those other shells, > that is because the inner shell chooses to ignore SIGQUIT, not because the > outer shell leaves it ignored.) Thanks for catching this. I have no idea how that got in there and it makes no sense whatsoever. This patch removes the if conditional. Fixes: e94a964e7dd0 ("eval: Add vfork support") Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | win32: allow use of /dev/ttyRon Yorston2025-11-101-1/+1
| | | | | | | | | | | | | | | | | | Treat /dev/tty as an alias for Windows' 'con' device. The code is similar to that used for /dev/null. Adds 24-48 bytes. (GitHub issue #538)
* | flock: enable by defaultRon Yorston2025-10-091-0/+11
| | | | | | | | | | | | | | | | | | Use the Gnulib implementation of flock(2) to allow the flock applet to be enabled. Costs 900-984 bytes. (GitHub issue #528)
* | win32: use RtlGenRandom for /dev/urandomRon Yorston2025-10-091-1/+0
| | | | | | | | | | | | | | | | | | Use the (somewhat ancient) Microsoft RtlGenRandom() function to provide random data for /dev/urandom. Saves 176-240 bytes. (GitHub issue #519)
* | Further mingw-w64/gcc build tweaksRon Yorston2025-10-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit 6481bb22b (win32: use 64-bit time on 32-bit platforms) fails to build with mingw32-gcc prior to mingw-w64 10.0.0. Don't used 64-bit time for such builds. mingw-w64 7.0.0 and below don't have some definitions required for native TLS support. This is enabled by default in the 64-bit Unicode build. Add the definitions required for the default build. TLS 1.3 support needs more but isn't enabled by default. (GitHub issue #527)
* | ash: eval: Add vfork supportRon Yorston2025-09-071-0/+2
| | | | | | | | | | | | | | Merge upstream commit df154028d. Since we don't have vfork() on Windows we continue to use the spawn_forkshell() mechanism. Although there is some rearrangement of the code it's functionally the same.
* | Merge branch 'busybox' into mergeRon Yorston2025-09-061-0/+3
|\|
| * top,pmap: speed up /smaps parsingDenys Vlasenko2025-08-061-0/+3
| | | | | | | | | | | | | | | | | | | | | | function old new delta procps_read_smaps 515 529 +14 procps_get_maps 685 665 -20 .rodata 105847 105820 -27 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/2 up/down: 14/-47) Total: -33 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | tls: rewrite Schannel codeRFL8902025-08-281-20/+20
| | | | | | | | | | The previous code had issues with buffer management, resulting in failures.
* | Merge branch 'busybox' into mergeRon Yorston2025-08-152-31/+39
|\|
| * top,pmap: do not use common code for reading /proc/PID/smapsDenys Vlasenko2025-08-051-29/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The logic is in fact quite far from common. While at it, stop accounting "---p" mappings as mapped (e.g. VSZ in top). Nothing is mapped there (why would kernel waste RAM to map pages which can't be accessed?). function old new delta read_smaps - 562 +562 read_cmdline 315 326 +11 print_smaprec 97 101 +4 procps_scan 1219 1211 -8 .rodata 115541 115533 -8 skip_whitespace_if_prefixed_with 25 - -25 procps_read_smaps 864 577 -287 ------------------------------------------------------------------------------ (add/remove: 1/1 grow/shrink: 2/3 up/down: 577/-328) Total: 249 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * ftpd: code shrink, move replace_char() to libbbDenys Vlasenko2025-08-021-0/+13
| | | | | | | | | | | | | | | | | | | | | | function old new delta modprobe_main 803 804 +1 escape_text 127 122 -5 replace 18 - -18 ------------------------------------------------------------------------------ (add/remove: 0/1 grow/shrink: 1/1 up/down: 1/-23) Total: -22 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * libbb/dump: much faster formatting of %_u on x86Denys Vlasenko2025-08-011-1/+1
| | | | | | | | | | | | | | function old new delta display 1485 1481 -4 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * ls: fix -Q to match GNUDenys Vlasenko2025-08-011-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta print_name 137 229 +92 display_files 375 402 +27 c_escape_conv_str00 - 24 +24 display 1476 1485 +9 conv_str 33 - -33 ------------------------------------------------------------------------------ (add/remove: 2/1 grow/shrink: 3/0 up/down: 152/-33) Total: 119 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
| * sha384sum: new appletAndy Knowles2025-07-301-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | function old new delta sha512384_end - 198 +198 packed_usage 35021 35134 +113 init384 - 80 +80 sha384_begin - 19 +19 sha384_end - 10 +10 applet_names 2823 2833 +10 md5_sha1_sum_main 501 507 +6 sha3_end 54 59 +5 applet_main 1628 1632 +4 show_usage_if_dash_dash_help 79 72 -7 hash_file 358 344 -14 sha512_end 197 10 -187 ------------------------------------------------------------------------------ (add/remove: 4/0 grow/shrink: 5/3 up/down: 445/-208) Total: 237 bytes Signed-off-by: Andy Knowles <aknowles@galleonec.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
* | Post-merge fixesRon Yorston2025-08-121-2/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Upstream has moved some functions from networking/tls.c to a new file, libbb/hash_hmac.c. The merge didn't adjust this code to allow it to work with the native Windows checksum API. This only matters if FEATURE_USE_CNG_API is enabled and CONFIG_FEATURE_TLS_SCHANNEL isn't. In that case the wget applet fails to handle https. None of the default configurations has this combination, but it should work. Make it so. The Windows code doesn't implement hmac_block(), as that's only used for password encryption which isn't currently supported. The variadic function hmac_peek_hash() isn't declared FAST_FUNC, as that causes clang to issue many warnings.
* | Merge branch 'busybox' into mergeRon Yorston2025-08-122-18/+73
|\|
| * password applets: update help textDenys Vlasenko2025-07-181-3/+3
| | | | | | | | Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>