paperbot · PL 论文追踪

全部论文 待读 收藏

P2 WasmRef-Isabelle: A Verified Monadic Interpreter and Industrial Fuzzing Oracle for WebAssembly

WasmRef-Isabelle:一个经验证的 WebAssembly 单子解释器与工业级模糊测试预言机
PLDI 7(PLDI)2023匹配度 4/10 · 该论文属于形式化验证与工业模糊测试预言机,具备机器化证明和工业部署亮点,但不涉及 LLM/Agent、静态分析、浮点程序分析或贝叶斯程序分析等画像核心交叉点。其形式化验证主题与 AI→PL 方向仅有间接关联,且并未使用 LLM/Agent 改进验证。引用 12 inbox
Conrad Watt, Maja Trela, Peter Lammich, Florian Märkl
crossref: 2026-09-10

AI 速览

一句话:在 Isabelle/HOL 中实现并机器化验证 WebAssembly 单子解释器,作为 Wasmtime 的模糊测试预言机,兼顾规范对应性与性能。

WebAssembly 官方 OCaml 参考解释器因性能不佳被 Wasmtime 放弃用作模糊测试预言机,而未经验证的预言机又难以保证与规范一致。本文提出 WasmRef-Isabelle:一个用 Isabelle/HOL 编写的 WebAssembly 单子解释器,并通过两步 refinement 证明其相对于 WasmCert-Isabelle 机械化形式化规范的正确性。该解释器已被部署到 Wasmtime 的持续集成基础设施中充当模糊测试预言机。实验表明其性能显著优于官方参考解释器,与工业级解释器 Wasmi 的 Rust debug 构建相当,在 Wasmtime 模糊测试基础设施中的吞吐量可与未经验证的预言机相比。此外,作者为 WasmCert-Isabelle 增加了对若干即将到来的 WebAssembly 特性的支持,并完整机器化了整数运算的数值语义,以增强其作为模糊测试预言机的实用性。

问题
官方 OCaml 参考解释器性能过差无法用作 Wasmtime 的模糊测试预言机,而实用性能好的预言机往往缺乏与 WebAssembly 规范的正确性保证。
方法
用 Isabelle/HOL 编写 WebAssembly 单子解释器 WasmRef-Isabelle,并以 WasmCert-Isabelle 的机械化规范为基准做两步 refinement 正确性证明,同时扩展该规范以支持新特性与整数数值语义。
评估
将 WasmRef-Isabelle 部署到 Wasmtime 的 CI 模糊测试基础设施中,与官方参考解释器、Wasmi 的 Rust debug 构建以及未验证预言机对比性能与模糊测试吞吐量。
原文摘要(Abstract)

We present WasmRef-Isabelle, a monadic interpreter for WebAssembly written in Isabelle/HOL and proven correct with respect to the WasmCert-Isabelle mechanisation of WebAssembly. WasmRef-Isabelle has been adopted and deployed as a fuzzing oracle in the continuous integration infrastructure of Wasmtime, a widely used WebAssembly implementation. Previous efforts to fuzz Wasmtime against WebAssembly's official OCaml reference interpreter were abandoned by Wasmtime's developers after the reference interpreter exhibited unacceptable performance characteristics, which its maintainers decided not to fix in order to preserve the interpreter's close definitional correspondence with the official specification. With WasmRef-Isabelle, we achieve the best of both worlds - an interpreter fast enough to be useable as a fuzzing oracle that also maintains a close correspondence with the specification through a mechanised proof of correctness. We verify the correctness of WasmRef-Isabelle through a two-step refinement proof in Isabelle/HOL. We demonstrate that WasmRef-Isabelle significantly outperforms the official reference interpreter, has performance comparable to a Rust debug build of the industry WebAssembly interpreter Wasmi, and competes with unverified oracles on fuzzing throughput when deployed in Wasmtime's fuzzing infrastructure. We also present several new extensions to WasmCert-Isabelle which enhance WasmRef-Isabelle's utility as a fuzzing oracle: we add support for a number of upcoming WebAssembly features, and fully mechanise the numeric semantics of WebAssembly's integer operations.

链接与引用

DOI 原文 · PDF(开放获取) ·

BibTeX
@article{paperbot2005,
  title = {WasmRef-Isabelle: A Verified Monadic Interpreter and Industrial Fuzzing Oracle for WebAssembly},
  author = {Conrad Watt and Maja Trela and Peter Lammich and Florian Märkl},
  journal = {Proceedings of the ACM on Programming Languages},
  volume = {7},
  number = {PLDI},
  year = {2023},
  doi = {10.1145/3591224}
}