Fuzzing the Rust Typechecker Using CLP

Fuzzing the Rust Typechecker Using CLP
复制标题

使用 CLP 模糊 Rust 类型检查器

DOI:
--
复制
发表时间:
2015
期刊:
影响因子:
--
通讯作者:
B. Hardekopf
B. Hardekopf
中科院分区:
--
文献类型:
--
作者:
Kyle Dewey;Jared Roesch;B. Hardekopf

文献摘要

被引文献

相似文献

语言模糊测试是一种用于测试编译器和解释器的错误查找技术;其有效性取决于以被测语言自动生成有效程序的能力。尽管语言模糊测试已被证明是成功的,但仍然严重缺乏使用高级类型系统对静态类型语言进行模糊测试的工具支持,因为现有的模糊测试技术无法有效地自动生成使用复杂类型的类型良好的程序。在这项工作中,我们通过用约束逻辑编程(CLP)来表述类型良好的程序生成问题来描述如何自动生成使用复杂类型系统的类型良好的程序。此外,我们还描述了如何专门针对类型检查器实现进行测试,这与所有忽略类型检查器的现有工作不同。我们专注于类型检查器精度错误、健全性错误和一致性错误。我们将我们的技术应用于 Rust,这是一种复杂的、工业强度的语言,具有复杂的类型系统。
Language fuzzing is a bug-finding technique for testing compilers and interpreters; its effectiveness depends upon the ability to automatically generate valid programs in the language under test. Despite the proven success of language fuzzing, there is a severe lack of tool support for fuzzing statically-typed languages with advanced type systems because existing fuzzing techniques cannot effectively and automatically generate well-typed programs that use sophisticated types. In this work we describe how to automatically generate well-typed programs that use sophisticated type systems by phrasing the problem of well-typed program generation in terms of Constraint Logic Programming (CLP). In addition, we describe how to specifically target the typechecker implementation for testing, unlike all existing work which ignores the typechecker. We focus on typechecker precision bugs, soundness bugs, and consistency bugs. We apply our techniques to Rust, a complex, industrialstrength language with a sophisticated type system.