[论文解读] Augmenting Greybox Fuzzing with Generative AI
ChatFuzz 在 AFL++ 的基础上增添了一个基于生成式AI的变异器,能够创建格式合规的输入,在12个程序和基准测试中,相较于 AFL++ 实现约 12.77% 的边缘覆盖提升。
Real-world programs expecting structured inputs often has a format-parsing stage gating the deeper program space. Neither a mutation-based approach nor a generative approach can provide a solution that is effective and scalable. Large language models (LLM) pre-trained with an enormous amount of natural language corpus have proved to be effective for understanding the implicit format syntax and generating format-conforming inputs. In this paper, propose ChatFuzz, a greybox fuzzer augmented by generative AI. More specifically, we pick a seed in the fuzzer's seed pool and prompt ChatGPT generative models to variations, which are more likely to be format-conforming and thus of high quality. We conduct extensive experiments to explore the best practice for harvesting the power of generative LLM models. The experiment results show that our approach improves the edge coverage by 12.77\% over the SOTA greybox fuzzer (AFL++) on 12 target programs from three well-tested benchmarks. As for vulnerability detection, \sys is able to perform similar to or better than AFL++ for programs with explicit syntax rules but not for programs with non-trivial syntax.
研究动机与目标
- 动机:在结构化数据程序的灰盒模糊测试中,格式合规输入的需求。
- 提出一种基于生成式 AI 的变异器,补充传统基于变异的模糊测试。
- 系统地研究 AI 变异器的超参数,以确定最佳实践。
- 在多样化目标上评估该方法,以衡量覆盖提升和种子贡献。
- 开源 ChatFuzz 及数据集,以实现可复现性。
提出的方法
- 将基于 AI 的 Chat 变异器与 AFL++ 集成,形成作为增强层的 ChatFuzz。
- 使用模糊测试器提供的种子输入来提示一个 ChatGPT 端点,以生成变体。
- 将 AI 的回应解析为新种子并反馈给模糊测试器以进行覆盖测试。
- 实验模型端点(chat 与 completion)及调优超参数(提示设计、max_tokens、n、temperature)。
- 评估跨越来自多个基准的十二个程序的边缘覆盖提升、种子多样性和句法有效性。
实验结果
研究问题
- RQ1ChatFuzz 对目标程序相比 AFL++ 能实现多少边缘覆盖提升?
- RQ2基于 AI 的变异器是否能够在不同输入格式上产生高质量、符合语法的种子?
- RQ3AI 模型选择与超参数如何影响模糊测试性能和 Seed 导入率?
- RQ4ChatFuzz 在输入语法复杂度各异的程序上是否对漏洞发现有效?
主要发现
- ChatFuzz 在平均意义上相对于 AFL++ 在 12 个程序上的边缘覆盖提升了 12.77%。
- AI 变异器平均贡献模糊测试器队列中约 12.77% 的种子,对某些程序的份额较高(例如 mujs、ossfuzz、lua 的份额 >30%)。
- 基于 ChatGPT 的变异器在使用 chat 模型(CT)时提供成更高的种子质量(独特且语法有效的种子),比完成模型(CP),尽管 CP 总体可生成更多种子。
- 格式感知型提示并在提示中包含示例输入,相较于不含输入的提示,显著提升覆盖率。
- 使用 CT 端点的 ChatFuzz 变体相对于 AFL++ 获得显著的覆盖提升,而对格式无关的变体仍然平均领先 AFL++ 大约 6%。
更好的研究,从现在开始
从论文设计到论文写作,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。