arrow
返回

LMFuzz: Program repair fuzzing based on large language models

delete2025-10-28
delete0
PRE
AI
L
Lin, Renze
R
Ran Wang *
G
Guanghuan Hu
X
Xianghua Xu
DOI:10.1007/s10515-025-00568-8delete
delete原文链接
delete原文求助
delete分享
delete收藏
摘要

摘要

En 中文
Generating programs using large language models (LLMs) for fuzz testing has emerged as a significant testing methodology. While traditional fuzzers can produce correct programs, their effectiveness is limited by excessive constraints and restricted API combinations, resulting in insufficient coverage of the target system's code and impacting testing efficiency. Unlike traditional methods, large language model based fuzzers can generate more diverse code, effectively addressing key issues of conventional fuzzers. However, the lack of constraints on API combinations during the generation process often leads to reduced program validity. Therefore, a crucial challenge is to enhance the validity of generated code while maintaining its diversity. To address this issue, we propose a novel and universal fuzzer, LMFuzz. To ensure the fuzzer's generation capability, we utilize a large language model as the primary generator and model the operator selection problem within the fuzzing loop as a multi-armed bandit problem. We introduce the Thompson Sampling algorithm to enhance both the diversity and validity of program generation. To improve the validity of the generated code, we incorporate a program repair loop that iteratively corrects the generated programs, thereby reducing errors caused by the lack of API combination constraints. Experimental results demonstrate that LMFuzz significantly surpasses existing state-of-the-art large language model based fuzzers in terms of coverage and validity, and also exhibits notable advantages in generating diverse programs. Furthermore, LMFuzz has identified 24 bugs across five popular programming languages and their corresponding systems.
Keyword:
Fuzzing
Large language model
Code generation
Thompson sampling algorithm
Program Repair
Software security

期刊

A
Automated Software Engineering
IF:
3.1
论文数:
84
被引数:
0

机构

H
hangzhou dianzi university
学者数:
1.3K
论文数: 507
被引数: 0
引用论文

引用论文

A systematic review of fuzzing based on machine learning techniques
err2020-08-18
err0
errOAAI
errYan Wang; Peng Jia; Luping Liu; Cheng Huang; Zhonglin Liu
err分享
err收藏
Fuzz4All: Universal Fuzzing with Large Language Models
err2024-04-12
err0
errOAAI
errChunqiu Steven Xia; Matteo Paltenghi; Jia Le Tian; Michael Pradel; Lingming Zhang
err分享
err收藏
Generation-based fuzzing? Don't build a new generator, reuse!
err2023-06-01
err1
PREAI
errPang, Chengbin; Liu, Hongbin; Wang, Yifan; Gong, Neil Zhenqiang; Mao, Bing; Xu, Jun
err分享
err收藏
MFTCoder: Boosting Code LLMs with Multitask Fine-TuningMFTCoder:通过多任务微调提升代码大语言模型
err2024-08-24
err0
errOAAI
errBingchang Liu; Chaoyu Chen; Zi Gong; Cong Liao; Huan Wang; Zhichao Lei; Ming Liang; Dajun Chen; Min Shen; Hailian Zhou; Wei Jiang; Hang Yu; Jianguo Li
err分享
err收藏
A Survey of Compiler Testing编译器测试综述
err2020-02-06
err114
PREAI
errChen, Junjie; Patra, Jibesh; Pradel, Michael; Xiong, Yingfei; Zhang, Hongyu; Hao, Dan; Zhang, Lu
err分享
err收藏
学者 查看更多内容