Fuzzing has been widely used for testing embedded-system firmware in a fully rehosted environment without real peripherals, native system supports, or access to the source code and specifications. Some fuzzers emulate the MMIO behavior of missing peripherals based on the firmware binaries to boost code coverage. They emulate each individual MMIO read in the firmware with a fixed model. We find this ineffective when multiple MMIO reads collectively retrieve a data chunk, which greatly impedes the coverage growth.
We propose ES-Fuzz to overcome this coverage bottleneck by adaptively modeling MMIO data chunks. ES-Fuzz runs alongside a given fuzzer and starts a new run when the fuzzer's coverage stagnates. In each run, it analyzes a high-coverage test case to infer new MMIO data-chunk models that unlock additional execution paths. We have implemented ES-Fuzz on Fuzzware and evaluated it on 24 popular firmware binaries. ES-Fuzz boosts Fuzzware's coverage by up to 68% in 11 -- and triggers additional bugs in 5 -- of them without degrading the coverage in the remainder. Its models describe a wide range of MMIO data chunks and the firmware's use of each across various contexts.
Protocol-Aware Firmware Rehosting for Effective Fuzzing of Embedded Network Stacks
CISPA Helmholtz Center for Information Security(CISPA 赫尔姆霍兹信息安全中心);Arizona State University(亚利桑那州立大学);Max Planck Institute for Security and Privacy(马克斯·普朗克安全与隐私研究所)
Stop Starving or Stuffing Me: Boosting Firmware Fuzzing Efficiency with On-demand Input Delivery
School of Cyber Science and Engineering, Huazhong University of Science and Technology(华中科技大学网络空间安全学院);Hubei Key Laboratory of Distributed System Security(湖北省分布式系统安全重点实验室);Penn State University(宾夕法尼亚州立大学);University of Texas at Dallas(德克萨斯大学达拉斯分校);University of Georgia(佐治亚大学)
SoK: A Large-Scale Empirical Study of Emulation-Based Dynamic Analysis Research for ARM Cortex-M Firmware (Extended Version)
School of Cyber Science and Engineering, Huazhong University of Science and Technology(华中科技大学网络空间安全学院);Hubei Key Laboratory of Distributed System Security(湖北省分布式系统安全重点实验室);University of Georgia(佐治亚大学)