File size: 3,669 Bytes
2686e9a
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
29c1bab
a3de7e3
ee3cbd7
 
 
 
29c1bab
a3de7e3
ee3cbd7
29c1bab
 
 
 
 
c6e77c9
29c1bab
 
 
a3de7e3
ee3cbd7
a3de7e3
ee3cbd7
 
 
 
a3de7e3
ee3cbd7
 
 
 
 
 
 
 
 
 
a3de7e3
ee3cbd7
c6e77c9
 
ee3cbd7
 
 
 
 
 
 
345f2aa
 
 
ee3cbd7
 
 
 
 
 
a3de7e3
ee3cbd7
 
 
 
eed4206
ee3cbd7
 
 
eed4206
 
ee3cbd7
 
 
 
eed4206
ee3cbd7
 
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
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
---
language:
- en
license: mit
tags:
- knowledge-graph
- rdf
- owl
- ontology
- cybersecurity
annotations_creators:
- expert-generated
pretty_name: D3FEND
size_categories:
- 100K<n<1M
task_categories:
- graph-ml
dataset_info:
  features:
    - name: subject
      dtype: string
    - name: predicate
      dtype: string
    - name: object
      dtype: string
  config_name: default
  splits:
    - name: train
      num_bytes: 46899451
      num_examples: 231842
  dataset_size: 46899451
viewer: false
---

# D3FEND: A knowledge graph of cybersecurity countermeasures

### Overview
D3FEND encodes a countermeasure knowledge base in the form of a
knowledge graph. It meticulously organizes key concepts and relations
in the cybersecurity countermeasure domain, linking each to pertinent
references in the cybersecurity literature. 

### Use-cases
Researchers and cybersecurity enthusiasts can leverage D3FEND to:
- Develop sophisticated graph-based models.
- Fine-tune large language models, focusing on cybersecurity knowledge
  graph completion.
- Explore the complexities and nuances of defensive techniques,
  mappings to MITRE ATT&CK, weaknesses (CWEs), and cybersecurity
  taxonomies.
- Gain insight into ontology development and modeling in the
  cybersecurity domain.

### Preprocessing

### Source:
- [Dataset Repository - 0.13.0-BETA-1](https://github.com/d3fend/d3fend-ontology/tree/release/0.13.0-BETA-1)
- [Commit Details](https://github.com/d3fend/d3fend-ontology/commit/3dcc495879bb62cee5c4109e9b784dd4a2de3c9d)
- [CWE Extension](https://github.com/d3fend/d3fend-ontology/tree/release/0.13.0-BETA-1/extensions/cwe)

#### Building and Verification:
1. **Construction**: The ontology, denoted as `d3fend-full.owl`, was
   built from the beta version of the D3FEND ontology referenced
   above using documented README in d3fend-ontology. This includes the
   CWE extensions. 
2. **Importation and Reasoning**: Imported into Protege version 5.6.1,
   utilizing the Pellet reasoner plugin for logical reasoning and
   verification.
3. **Coherence Check**: Utilized the Debug Ontology plugin in Protege
   to ensure the ontology's coherence and consistency.

#### Exporting, Transformation, and Compression:
Note: The following steps were performed using Apache Jena's command
line tools. (https://jena.apache.org/documentation/tools/)
1. **Exporting Inferred Axioms**: Post-verification, I exported
   inferred axioms along with asserted axioms and
   annotations. [Detailed
   Process](https://www.michaeldebellis.com/post/export-inferred-axioms)
2. **Filtering**: The materialized ontology was filtered using
   `d3fend.rq` to retain relevant triples.
3. **Format Transformation**: Subsequently transformed to Turtle and
   N-Triples formats for diverse usability. Note: I export in Turtle
   first because it is easier to read and verify. Then I convert to
   N-Triples.
   ```shell
   arq --query=d3fend.rq --data=d3fend.owl --results=turtle > d3fend.ttl
   riot --output=nt d3fend.ttl > d3fend.nt
   ```
4. **Compression**: Compressed the resulting ontology files using
   gzip.

### How to Load the Dataset:

You can load this dataset using the Hugging Face Datasets library with
the following Python code:

```python
from datasets import load_dataset
dataset = load_dataset('wikipunk/d3fend', split='train')
```

### Acknowledgements
This ontology is developed by MITRE Corporation and is licensed under
the MIT license. I would like to thank the authors for their work
which has opened my eyes to a new world of cybersecurity modeling.

If you are a cybersecurity expert please consider [contributing to
D3FEND](https://d3fend.mitre.org/contribute/).