Refploit: 通过代码代理轨迹修复促进漏洞利用构建
Refploit: Facilitating Exploit Construction via Code-Agent Trajectory Repair
AI总结:
提出Refploit框架,利用大语言模型修复代码代理生成的失败轨迹,通过差分执行验证和约束引导恢复,在Java漏洞数据集上实现80.2%的复现率,相对初始轨迹提升64.3%。
摘要:
漏洞利用在评估Java库漏洞的下游影响中起着关键作用。虽然某些漏洞附带有公开的利用参考,但将这些参考自动复现为可运行的利用仍然具有挑战性,因为它们通常不完整、非结构化或仅描述部分复现步骤。最近的代码代理提供了一种自动化该过程的有前景的方法,但我们的研究表明,它们生成的利用通常看似成功,却未触发实际的漏洞逻辑,例如用自实现函数替换易受攻击的API。为解决此问题,我们提出Refploit,一种基于LLM的轨迹恢复框架,用于从公开利用参考中促进漏洞复现。关键洞察在于,失败的代理轨迹并非完全无用。它可能已经完成了一些复现子任务,同时也揭示了应避免的误导方向。Refploit首先通过差分执行验证代理生成的利用。当利用无效时,Refploit分析其复现进度,定位与复现进度相关的轨迹片段,并推导出约束以引导有针对性的恢复。我们在三个开源Java漏洞数据集上评估Refploit,涵盖143个漏洞的172个利用参考。在DeepSeek-V4-Flash下,Refploit成功复现了138个利用,复现率达到80.2%。相比初始生成的轨迹,它实现了64.3%的相对改进,并优于最先进的利用生成方法PoCGen和高级代码代理(如使用GPT-5.4的Codex)。我们进一步将Refploit适配到另一个代码代理,观察到一致的改进,证明了其通用性。
英文摘要:
Vulnerability exploits play a crucial role in assessing the downstream impact of Java library vulnerabilities. While some vulnerabilities are accompanied by disclosed exploit references, automatically reproducing such references into runnable exploits remains challenging because they are often incomplete, unstructured, or only describe partial reproduction steps. Recent code agents provide a promising way to automate this process, but our study shows that their generated exploits often appear successful without triggering the actual vulnerable logic, such as replacing vulnerable APIs with self-implemented functions. To address this, we propose Refploit, an LLM-based trajectory recovery framework for facilitating vulnerability reproduction from public exploit references. The key insight is that a failed agent trajectory is not entirely useless. It may have already completed some reproduction subtasks while also revealing misleading directions that should be avoided. Refploit first validates an agent-generated exploit through differential execution. When the exploit is ineffective, Refploit analyzes its reproduction progress, locates the trajectory segments associated with the reproduction progress, and derives constraints to guide focused recovery. We evaluate Refploit on three open-source Java vulnerability datasets, covering 172 exploit references for 143 vulnerabilities. Under DeepSeek-V4-Flash, Refploit successfully reproduces 138 exploits, achieving a reproduction rate of 80.2%. It achieves a 64.3% relative improvement over the initially generated trajectories and outperforms both the SOTA exploit-generation method PoCGen and advanced code agents such as Codex with GPT-5.4. We further adapt Refploit to another code agent and observe consistent improvements, demonstrating its generality.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。