一句话:首个基于 Wasm 字节码变异的模糊测试工具,利用代码片段替换生成多样且合法的测试用例。
WebAssembly 运行时的可靠性至关重要,但为其生成兼具多样性与合法性的测试用例十分困难。本文提出 Wapplique,首个基于 Wasm 字节码变异的模糊测试工具。它采用面向 Wasm 的执行上下文感知代码片段替换方法:从真实程序中抽取代码片段并注入种子程序,以提升测试多样性;同时通过精心设计的代码分析算法保证变异后程序的合法性。由此 Wapplique 能高效生成大量合法且多样的 Wasm 程序来充分测试目标运行时。作者在四个主流真实运行时上开展评估,结果表明 Wapplique 能高效生成测试用例、达到高覆盖率,并发现 20 个此前未知的 bug。
Reliability is the top concern to runtimes. This paper studies how to test Wasm runtime, by presenting Wapplique, the first Wasm bytecode mutation-based fuzzing tool. Wapplique solves the diversity/efficiency dilemma in generating test cases with a specifically-tailored code-fragment substitution approach for Wasm. In particular, Wapplique appliqués code fragments from real-world programs to seed programs to enhance the diversity of the seeds. Via sophisticated code analysis algorithms we design, Wapplique also guarantees the validity of the resulting programs. This allows Wapplique to generate tremendous valid and diverse Wasm programs as test cases to well exercise target runtimes. Our experiences on applying Wapplique in testing four prevalent real-world runtimes indicate that it can generate test cases efficiently, achieve high coverage, and find 20 previously unknown bugs.
DOI 原文 ·
@inproceedings{paperbot8601,
title = {Wapplique: Testing WebAssembly Runtime via Execution Context-Aware Bytecode Mutation},
author = {Wenxuan Zhao and Ruiying Zeng and Yangfan Zhou},
booktitle = {ISSTA},
year = {2024},
doi = {10.1145/3650212.3680340}
}