Skip to main content
QUICK REVIEW

[Paper Review] SourceFinder: Finding Malware Source-Code from Publicly Available Repositories

Md Omar Faruk Rokon, Risul Islam|arXiv (Cornell University)|May 28, 2020
Advanced Malware Detection TechniquesComputer Science49 references10 citations
TL;DR

SourceFinder is a supervised machine learning system that identifies malware source-code repositories in public code archives like GitHub with 89% precision and 86% recall. It leverages keyword-based collection and feature engineering across repository metadata to curate the largest known non-commercial malware source code database—7,504 repositories—enabling new research in malware analysis and reverse engineering.

ABSTRACT

Where can we find malware source code? This question is motivated by a real need: there is a dearth of malware source code, which impedes various types of security research. Our work is driven by the following insight: public archives, like GitHub, have a surprising number of malware repositories. Capitalizing on this opportunity, we propose, SourceFinder, a supervised-learning approach to identify repositories of malware source code efficiently. We evaluate and apply our approach using 97K repositories from GitHub. First, we show that our approach identifies malware repositories with 89% precision and 86% recall using a labeled dataset. Second, we use SourceFinder to identify 7504 malware source code repositories, which arguably constitutes the largest malware source code database. Finally, we study the fundamental properties and trends of the malware repositories and their authors. The number of such repositories appears to be growing by an order of magnitude every 4 years, and 18 malware authors seem to be "professionals" with well-established online reputation. We argue that our approach and our large repository of malware source code can be a catalyst for research studies, which are currently not possible.

Motivation & Objective

  • To address the critical scarcity of publicly available malware source code, which hinders security research and tool evaluation.
  • To systematically identify malware source-code repositories in large public archives like GitHub, which remain underexplored despite their prevalence.
  • To develop a scalable, supervised learning approach that accurately distinguishes malware repositories from benign ones using metadata features.
  • To construct a large, curated, and persistent database of malware source code for future research.
  • To analyze trends in malware repository growth and author behavior, including the emergence of professional malware authors.

Proposed method

  • Collect 97,000 GitHub repositories using 137 malware-related keywords to form an initial candidate set.
  • Create a ground truth dataset of 2,013 repositories manually labeled as malware or benign for model training and evaluation.
  • Extract and engineer features from five repository fields: title, description, readme, language, and topics.
  • Train a supervised machine learning classifier (e.g., XGBoost or similar) on the engineered features to distinguish malware repositories.
  • Apply the trained model to the full candidate set to identify 7,504 malware source-code repositories.
  • Validate the model’s performance using precision, recall, and F1-score on a held-out test set.

Experimental results

Research questions

  • RQ1Can a supervised machine learning approach effectively identify malware source-code repositories in public code archives like GitHub with high precision and recall?
  • RQ2What are the key metadata features that best distinguish malware repositories from benign ones in public repositories?
  • RQ3How many malware source-code repositories exist on GitHub, and what are their growth trends over time?
  • RQ4Who are the most active and influential malware authors, and do they exhibit professional behavior patterns?
  • RQ5Can the identified malware repository database support new research in malware analysis, reverse engineering, and tool evaluation?

Key findings

  • SourceFinder achieves 89% precision, 86% recall, and 87% F1-score in identifying malware repositories using five repository metadata fields.
  • The study identifies 7,504 malware source-code repositories on GitHub, constituting the largest known non-commercial malware source code database.
  • The number of new malware repositories grows by more than threefold every four years, indicating a rapidly expanding ecosystem.
  • 18 malware authors exhibit professional behavior, including consistent contributions, high repository quality, and strong online reputations.
  • The approach generalizes to other public code archives like GitLab and BitBucket, given similar metadata structures and public repository access.
  • The authors intend to release both the SourceFinder model and the curated malware source code database to support future research.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.