Abstract
Coverage-based Greybox Fuzzing (CGF) is an efficient technique for detecting software vulnerabilities. However, efficient compile-time instrumentation utilized by some fuzzers is not available in testing closed-source binary. Therefore, researchers have proposed hardware-assisted fuzzing to address this. Though enhancing the efficiency in rebuilding coverage, hardware-assisted fuzzing performs poorly on some binaries due to the absence of the fork server, which is an efficient mechanism in modern fuzzers. The program patched with the fork server goes through initialization stages only once during repeated testing, which can significantly improve fuzzing performance. However, existing hardware-assisted fuzzers cannot place the fork server in some (statically linked) binaries. In this paper, we propose ReForker, a trampoline x86_64 binary rewriter to instrument the binary with the fork server for improving the efficiency of hardware-assisted fuzzing. Different from some rewriters in CGF, ReForker focuses on additive instrumentation and is not limited by symbolic information or Position-Independent Executable (PIE) code. It searches the sections in ELF for an executable one as the trampoline section, to insert the fork server. Then ReForker rewrites the instruction storing the address of the main function to redirect the control flow to the fork server, avoiding disturbing the layout of the original code and data sections. The evaluation shows that ReForker effectively works on real-world programs, including statically linked, PIE, and stripped binaries, with only increasing the file size by 4KB and introducing negligible runtime overhead on SPEC INT2006.
Funding Information
  • Natural Science Foundation of Hunan Province of China (No.2021JJ40692)
  • National Key Research and Development Program of China (2021YFB0300101)
  • National University of Defense Technology Foundation (Nos. ZK20-09)
  • National Natural Science Foundation China (62272472)