File size: 2,182 Bytes
3e2f259
d11ac9a
3e2f259
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
d11ac9a
 
 
 
3e2f259
d11ac9a
9405b51
 
d11ac9a
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
---
arxiv: 1801.01681
dataset_info:
  features:
  - name: functionSource
    dtype: string
  - name: fName
    dtype: string
  - name: oriFile
    dtype: string
  - name: startEndLine
    dtype: string
  - name: label
    dtype: int64
  - name: vulLine
    dtype: int64
  - name: cwe
    dtype: string
  splits:
  - name: train
    num_bytes: 114905147
    num_examples: 128118
  - name: validation
    num_bytes: 14289221
    num_examples: 16015
  - name: test
    num_bytes: 14618528
    num_examples: 16015
  download_size: 52698659
  dataset_size: 143812896
configs:
- config_name: default
  data_files:
  - split: train
    path: data/train-*
  - split: validation
    path: data/validation-*
  - split: test
    path: data/test-*
task_categories:
- text-classification
tags:
- code
---

This is an unofficial HuggingFace version of "[VulDeePecker: A Deep Learning-Based System for Vulnerability Detection
](https://arxiv.org/abs/1801.01681)" dataset.
***
Database of "VulDeePecker: A Deep Learning-Based System for Vulnerability Detection" (NDSS'18)
***

Code Gadget Database (CGD) focuses on two types of vulnerabilities in C/C++ programs, buffer error vulnerability (CWE-119) and resource management error vulnerability (CWE-399).  Each code gadget is composed of a number of program statements (i.e., lines of code), which are related to each other according to the data flow associated to the arguments of some library/API function calls.

Based on the National Vulnerability Database (NVD) and the NIST Software Assurance Reference Dataset (SARD) project, we collect 520 open source software program files with corresponding diff files and 8,122 test cases for the buffer error vulnerability, and 320 open source software program files with corresponding diff files and 1,729 test cases for the resource management error vulnerability.

In total, the CGD database contains 61,638 code gadgets, including 17,725 code gadgets that are vulnerable and 43,913 code gadgets that are not vulnerable. Among the 17,725 code gadgets that vulnerable, 10,440 corresponds to buffer error vulnerabilities and the rest 7,285 corresponds to resource management error vulnerabilities.