You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
# Disabled because we have a lot of long lines. We should fix this eventually.
9
+
MD013: false
10
+
# 033 Inline HTML
11
+
# Disabled because we use inline HTML (<br/> in table cells for example)
12
+
MD033: false
13
+
# MD040/fenced-code-language : Fenced code blocks should have a language specified : https://github.com/DavidAnson/markdownlint/blob/v0.37.4/doc/md040.md
14
+
MD040: false
15
+
# 041 First line in file should be a top level header
16
+
# Disabled because we use `include-markdown` plugin for merging markdown files
17
+
MD041: false
18
+
# 046 Code block style
19
+
# Disabled because mkdocs-material uses indented blocks for admonitions
Copy file name to clipboardExpand all lines: README.md
+75-16Lines changed: 75 additions & 16 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,7 +10,7 @@ SSVC aims to avoid one-size-fits-all solutions in favor of a modular decision-ma
10
10
SSVC is mostly conceptual tools for vulnerability management.
11
11
These conceptual tools (how to make decisions, what should go into a decision, how to document and communicate decisions clearly, etc.) are described here.
12
12
13
-
**Note:** This repository contains the _content_ for the main SSVC documentation hosted at
13
+
**Note:** This repository contains the *content* for the main SSVC documentation hosted at
@@ -19,7 +19,6 @@ These conceptual tools (how to make decisions, what should go into a decision, h
19
19
20
20
---
21
21
22
-
23
22
# What's here
24
23
25
24
Here's a quick overview of the main directories and files in this repository.
@@ -34,7 +33,7 @@ See [`project_docs/README.md`](project_docs/README.md) for more info.
34
33
Directory with SSVC calculator using D3 graph.
35
34
See [`ssvc-calc/README.md`](docs/ssvc-calc/README.md) for more info.
36
35
37
-
A demo version of `ssvc-calc` can be found at https://certcc.github.io/SSVC/ssvc-calc/
36
+
A demo version of `ssvc-calc` can be found at <https://certcc.github.io/SSVC/ssvc-calc/>
38
37
39
38
## `/pdfs/*`
40
39
@@ -82,12 +81,57 @@ The two methods just loop through their respective lookup tables until
82
81
they hit a match, then return the outcome. Maybe not the best implementation,
83
82
but it worked well enough for what was needed at the time.
84
83
85
-
86
84
## Local development
87
85
88
-
Install prerequisites:
86
+
The simplest way to get started with local development is to use Docker.
87
+
We provide a Dockerfile that builds an image with all the dependencies needed to build the site.
88
+
We also provide a `Makefile` that simplifies the process of building the site and running a local server,
89
+
so you don't have to remember the exact `docker build` and `docker run` commands
90
+
to get started.
91
+
92
+
### Make Commands
93
+
94
+
To display the available `make` commands, run:
95
+
96
+
```bash
97
+
make help
98
+
```
99
+
100
+
To preview any `make` command without actually executing it, run:
89
101
90
102
```bash
103
+
make -n <command>
104
+
```
105
+
106
+
### Run Local Server With Docker
107
+
108
+
The easiest way to get started is using make to build a docker image and run the site:
109
+
110
+
```bash
111
+
make docs
112
+
```
113
+
114
+
Then navigate to <http://localhost:8765/SSVC/> to see the site.
115
+
116
+
Note that the docker container will display a message with the URL to visit, for
117
+
example: `Serving on http://0.0.0.0:8000/SSVC/` in the output. However, that port
118
+
is only available inside the container. The host port 8765 is mapped to the container's
119
+
port 8000, so you should navigate to <http://localhost:8765/SSVC/> to see the site.
120
+
121
+
Or, if make is not available:
122
+
123
+
```bash
124
+
docker build --target docs --tag ssvc_docs .
125
+
docker run --tty --rm -p 8765:8000 --volume .:/app ssvc_docs
126
+
```
127
+
128
+
### Run Local Server Without Docker
129
+
130
+
If you prefer to run the site locally without Docker, you can do so with mkdocs.
131
+
We recommend using a virtual environment to manage dependencies:
132
+
133
+
```bash
134
+
python3 -m venv ssvc_venv
91
135
pip install -r requirements.txt
92
136
```
93
137
@@ -97,32 +141,47 @@ Start a local server:
97
141
mkdocs serve
98
142
```
99
143
100
-
Navigate to http://localhost:8001/ to see the site.
144
+
By default, the server will run on port 8001.
145
+
This is configured in the `mkdocs.yml` file.
146
+
Navigate to <http://localhost:8001/> to see the site.
101
147
102
148
(Hint: You can use the `--dev-addr` argument with mkdocs to change the port, e.g. `mkdocs serve --dev-addr localhost:8000`)
103
149
104
-
## Run tests
150
+
## Run tests
105
151
106
152
We include a few tests for the `ssvc` module.
107
153
108
-
### With Docker
154
+
### Run Tests With Docker
109
155
110
-
```bash
156
+
The easiest way to run tests is using make to build a docker image and run the tests:
111
157
112
-
docker build -t ssvc_test .
113
-
docker run -it --rm ssvc_test
158
+
```bash
159
+
make docker_test
114
160
```
115
161
116
-
### Without Docker
162
+
Or, if make is not available:
117
163
118
164
```bash
119
-
pip install pytest # if you haven't already
165
+
docker build --target test --tag ssvc_test .
166
+
docker run --tty --rm --volume .:/app ssvc_test
167
+
```
168
+
169
+
### Run Tests Without Docker
120
170
121
-
pytest # should find tests in src/test/*
171
+
```bash
172
+
pip install pytest
173
+
pytest src/test
122
174
```
123
175
176
+
## Environment Variables
124
177
178
+
If you encounter a problem with the `ssvc` module not being found, you may need to set the `PYTHONPATH` environment variable.
179
+
The Dockerfile takes care of this in the Docker environment.
180
+
When not running in Docker, make sure that the `src` directory is in your `PYTHONPATH`:
125
181
182
+
```bash
183
+
export PYTHONPATH=$PYTHONPATH:$(pwd)/src
184
+
```
126
185
127
186
## Contributing
128
187
@@ -147,5 +206,5 @@ To reference SSVC in an academic publication, please refer to the version presen
147
206
148
207
## References
149
208
150
-
1. Spring, J., Hatleback, E., Householder, A., Manion, A., and Shick, D. "Prioritizing Vulnerability Response: A Stakeholder-Specific Vulnerability Categorization." White Paper, Software Engineering Institute, Carnegie Mellon University (2019). https://resources.sei.cmu.edu/library/asset-view.cfm?assetid=636379
151
-
2. Spring, J., Hatleback, E., Householder, A., Manion, A., and Shick, D. "Towards Improving CVSS." White Paper, Software Engineering Institute, Carnegie Mellon University (2018). https://resources.sei.cmu.edu/library/asset-view.cfm?assetid=538368
209
+
1. Spring, J., Hatleback, E., Householder, A., Manion, A., and Shick, D. "Prioritizing Vulnerability Response: A Stakeholder-Specific Vulnerability Categorization." White Paper, Software Engineering Institute, Carnegie Mellon University (2019). <https://resources.sei.cmu.edu/library/asset-view.cfm?assetid=636379>
210
+
2. Spring, J., Hatleback, E., Householder, A., Manion, A., and Shick, D. "Towards Improving CVSS." White Paper, Software Engineering Institute, Carnegie Mellon University (2018). <https://resources.sei.cmu.edu/library/asset-view.cfm?assetid=538368>
0 commit comments