paper-with-me

홈 › Papers

Automatically Generating Rules of Malicious Software Packages via Large Language Model

2025-04-24 · XiangRui Zhang, Haoyu Chen, Yongzhong He, Wenjia Niu, Qiang Li

Today's security tools predominantly rely on predefined rules crafted by experts, making them poorly adapted to the emergence of software supply chain attacks. To tackle this limitation, we propose a novel tool, RuleLLM, which leverages large language models (LLMs) to automate rule generation for OSS ecosystems. RuleLLM extracts metadata and code snippets from malware as its input, producing YARA and Semgrep rules that can be directly deployed in software development. Specifically, the rule generation task involves three subtasks: crafting rules, refining rules, and aligning rules. To validate RuleLLM's effectiveness, we implemented a prototype system and conducted experiments on the dataset of 1,633 malicious packages. The results are promising that RuleLLM generated 763 rules (452 YARA and 311 Semgrep) with a precision of 85.2\% and a recall of 91.8\%, outperforming state-of-the-art (SOTA) tools and scored-based approaches. We further analyzed generated rules and proposed a rule taxonomy: 11 categories and 38 subcategories.

📄 PDF Abstract BibTeX arXiv:2504.17198

Code (0)

등록된 구현이 없습니다.

Tasks

Language ModelingLanguage ModellingLarge Language Model

Similar Papers 제목 키워드 기반

One Detector Fits All: Robust and Adaptive Detection of Malicious Packages from PyPI to Enterprises

2025-12-03 · Biagio Montaruli, Luca Compagna, Serena Elisa Ponta, Davide Balzarotti arxiv

The rise of supply chain attacks via malicious Python packages demands robust detection solutions. Current approaches, however, overlook two critical challenges: robustness against adversarial source code transformations…

Malicious Source Code Detection Using Transformer

2022-09-16 · Chen Tsfaty, Michael Fire

Open source code is considered a common practice in modern software development. However, reusing other code allows bad actors to access a wide developers' community, hence the products that rely on it. Those attacks are…

Leveraging Large Language Models to Detect npm Malicious Packages

2024-03-18 · Nusrat Zahan, Philipp Burckhardt, Mikola Lysenko, Feross Aboukhadijeh 외

Existing malicious code detection techniques demand the integration of multiple tools to detect different malware patterns, often suffering from high misclassification rates. Therefore, malicious code detection technique…

Malware Detection

LLM-Enhanced Hierarchical Heterogeneous Graph Representation Learning for Malicious Python Package Detection

2026-07-03 · Hang Gao, Xiaoyu Chen, Baoquan Cui, Zhen Tang 외 arxiv

Malicious Python packages have become a major threat to software supply chain ecosystems due to the widespread adoption of open-source repositories such as PyPI. Existing learning-based detection methods struggle to capt…

Graph Representation LearningGraph Neural Network

Many-Objective Software Remodularization using NSGA-III

2020-05-13 · Mohamed Wiem Mkaouer, Marouane Kessentini, Adnan Shaout, Patrice Koligheu 외

Software systems nowadays are complex and difficult to maintain due to continuous changes and bad design choices. To handle the complexity of systems, software products are, in general, decomposed in terms of packages/mo…