eyeballvul
收藏资源简介:
eyeballvul数据集由Timothée Chauvin创建,旨在评估语言模型在大规模环境中检测安全漏洞的能力。该数据集包含超过24,000个真实世界中的漏洞,来源于开源仓库中的CVEs,并每周更新以保持时效性。数据集大小超过55GB,涉及多种编程语言,适用于测试和改进静态应用安全测试工具。创建过程中,数据集通过重新包装现有的CVEs数据,确保每个修订版本关联已知漏洞,以真实反映漏洞检测的实际情况。该数据集主要用于提升模型在实际应用中识别和分类安全漏洞的能力。
The EyeballVul dataset was created by Timothée Chauvin, aiming to evaluate the capability of language models to detect security vulnerabilities in large-scale environments. This dataset contains over 24,000 real-world vulnerabilities sourced from CVEs in open-source repositories, and it is updated weekly to maintain timeliness. With a size exceeding 55 GB, it covers multiple programming languages and is applicable for testing and improving static application security testing tools. During its creation, existing CVE data was repackaged to ensure that each revised version is associated with known vulnerabilities, thus realistically reflecting the actual scenario of vulnerability detection. This dataset is primarily used to enhance the ability of models to identify and classify security vulnerabilities in real-world applications.
eyeballvul 数据集概述
数据集简介
eyeballvul 是一个开源基准测试数据集,旨在评估基于语言模型的静态应用安全测试(SAST)漏洞检测工具。该数据集每周从开源仓库的 CVE 流中更新,确保其在未来一段时间内保持相关性。
数据集内容
eyeballvul 包含 24,643 个漏洞,分布在 6,525 个修订版本和 5,974 个仓库中。每个漏洞对应于 osv.dev 数据库中的一个条目(通常是一个 CVE),并可能存在于多个仓库修订版本中。每个修订版本代表仓库在特定提交时的状态,并可能与多个漏洞相关联。
数据模型
数据集中的数据分为两种类型:漏洞和修订版本。漏洞包含 ID、发布日期、修改日期、详细信息、严重性、仓库 URL 等信息。修订版本包含提交哈希、仓库 URL、日期、语言分布和大小等信息。
使用方法
数据集的使用通常包括以下步骤:
- 选择一个包含至少一个在某个日期之后发布的漏洞的仓库和修订版本列表;
- 在每个修订版本的源代码上运行 SAST 工具(通常基于 LLM);
- 将 SAST 工具的结果与每个修订版本的已知漏洞列表进行比较,特别是那些在训练数据截止日期之后发布的漏洞。
安装与导入
可以通过以下命令安装和导入数据集: bash pip install eyeballvul
python from eyeballvul import download_data download_data()
如果需要特定版本的数据,可以使用 download_data(date="YYYY-MM-DD") 命令。
数据查询
数据集提供了多个查询函数,如 get_projects、get_commits、get_revisions 和 get_vulns,用于获取项目列表、提交列表、修订版本列表和漏洞列表。这些函数支持按日期、项目和提交哈希进行过滤。
示例
以下是一个使用数据集的示例,展示了如何获取特定项目的漏洞和修订版本信息: python from eyeballvul import get_vulns, get_revision import json
vulnerability = get_vulns(project="https://github.com/gnome/nautilus")[0] print(json.dumps(vulnerability.to_dict(), indent=2))
revision = get_revision(vulnerability.commits[0]) print(json.dumps(revision.to_dict(), indent=2))

- 1eyeballvul: a future-proof benchmark for vulnerability detection in the wild未提及 · 2024年



