arXivDaily arXiv每日学术速递 周一至周五更新
感恩节,周五至周末无更新,大家顺遂。周一再来吧
arXiv 2601.16458cs.SEcs.CR
收藏

弥合专家推理与大语言模型检测:一种基于知识的恶意包检测框架

Bridging Expert Reasoning and LLM Detection: A Knowledge-Driven Framework for Malicious Packages

Nanyang Technological University(南洋理工大学);Singapore Management University(新加坡管理大学);Sichuan University(四川大学);Imperial Global Singapore(帝国理工学院新加坡校区)

Wenbo Guo, Shiwen Song, Jiaxun Guo, Zhengzi Xu, Chengwei Liu, Haoran Ou, Mengmeng Ge, Yang Liu

AI总结:

IntelGuard通过整合专家推理与大语言模型,实现高准确率的恶意包检测,发现54个未报告恶意包。

摘要:

开源生态系统如NPM和PyPI正日益受到供应链攻击的威胁,但现有检测方法要么依赖于脆弱的手工规则,要么依赖于数据驱动的特征,这些特征无法捕捉不断演变的攻击语义。我们提出了IntelGuard,一种基于检索增强生成(RAG)的框架,该框架将专家分析推理整合到自动恶意包检测中。IntelGuard从超过8000份威胁情报报告中构建了一个结构化的知识库,将恶意代码片段与行为描述和专家推理联系起来。在分析新包时,它检索语义相似的恶意示例,并应用LLM引导的推理来评估代码行为是否符合预期功能。在427个真实世界包上的实验表明,IntelGuard实现了99%的准确率和0.50%的误报率,同时在混淆代码上保持96.5%的准确率。部署在PyPI.org上时,它发现了54个此前未报告的恶意包,展示了由专家知识引导的可解释且稳健的检测。

英文摘要:

Open-source ecosystems such as NPM and PyPI are increasingly targeted by supply chain attacks, yet existing detection methods either depend on fragile handcrafted rules or data-driven features that fail to capture evolving attack semantics. We present IntelGuard, a retrieval-augmented generation (RAG) based framework that integrates expert analytical reasoning into automated malicious package detection. IntelGuard constructs a structured knowledge base from over 8,000 threat intelligence reports, linking malicious code snippets with behavioral descriptions and expert reasoning. When analyzing new packages, it retrieves semantically similar malicious examples and applies LLM-guided reasoning to assess whether code behaviors align with intended functionality. Experiments on 4,027 real-world packages show that IntelGuard achieves 99% accuracy and a 0.50% false positive rate, while maintaining 96.5% accuracy on obfuscated code. Deployed on PyPI.org, it discovered 54 previously unreported malicious packages, demonstrating interpretable and robust detection guided by expert knowledge.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑