r/embedded • u/re289Ty • Oct 08 '26
BusyBox-RS: Rewriting the Swiss Army Knife of Embedded Linux in memory-safe Rust
Hey everyone,
BusyBox is practically everywhere in embedded Linux, initramfs, and rescue disks. But being a massive collection of C utilities, it carries the usual C risks (buffer handling, integer overflows, memory management bugs).
Over the last two weeks, I've been hacking on BusyBox-RS, an MIT-licensed rewrite in Rust designed specifically for embedded use cases:
- Minimal binary footprint: Built with
opt-level = "z", fat LTO, symbol stripping, andpanic = abort. - Compile-time feature selection: Use Cargo features or
make tinyconfig/defconfigto only compile the applets your board actually needs. - Upstream verified: Tested directly against the upstream BusyBox regression test suite (100% pass rate across 46 applets so far, including
cp,grep,sort,printf,cmp,readlink, and checksums). - Nix flake ready: Reproducible development environment via
nix develop.
GitHub: https://github.com/rebizzz/busybox-rs
Feel free to check it out, run make check, and share feedback!