This research presents a comparative analysis of the safety and security characteristics of C and Rust on Raspberry Pi systems. Using a Raspberry Pi 3 Model B+ running a 64-bit Linux environment, the study evaluates how both programming languages behave under controlled test cases involving common software vulnerabilities and runtime failures. The experiments examine buffer overflow, use-after-free and dangling pointers, integer overflow, format-string vulnerabilities, stack exhaustion, heap allocation, null pointer handling, and thread panic behavior. The study focuses on the differences between C's manual memory management model and Rust's ownership, borrowing, type-safety, and runtime safety mechanisms. Experimental results demonstrate how several vulnerability classes can compile and reach execution in C, while safe Rust prevents or detects many comparable unsafe operations through compile-time checks, explicit APIs, or runtime panics. The research also discusses the limitations of the experimental environment and the implications of adopting Rust for memory-safe systems programming on ARM-based embedded and edge-computing platforms.
No takes yet. Share an insight, caveat, or question.
Gio Rivera (2026) studied this question.
Synapse has enriched 5 closely related papers on similar clinical questions. Consider them for comparative context: