Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@
}
},
"required": [
"definition",
"key"
],
"type": "object"
Expand Down Expand Up @@ -154,7 +153,6 @@
"namespace",
"key",
"version",
"definition",
"values"
],
"type": "object"
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"target_ids": ["CVE-1900-1234"],
"timestamp": "2021-09-29T15:29:44Z",
"schemaVersion": "2.0.0",
"selections": [
{
"namespace": "ssvc",
"name": "Exploitation",
"key": "E",
"version": "1.1.0",
"values": [
{"name":"Active", "key": "A"}
]
},
{
"namespace": "ssvc",
"name": "Automatable",
"key": "A",
"version": "2.0.0",
"values": [
{"name": "Yes", "key": "Y"}
]
},
{
"namespace": "ssvc",
"name": "Technical Impact",
"key": "TI",
"version": "1.0.0",
"values": [
{"name": "Total","key":"T"}
]
}
]
}
4 changes: 2 additions & 2 deletions src/ssvc/doctools.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@

To generate the documentation for the decision points, use the following command:

python -m ssvc.doctools --overwrite --jsondir ./tmp/json_out`
python -m ssvc.doctools --overwrite --datadir ./tmp/json_out`

To regenerate the existing docs, use the following command:

python -m ssvc.doctools --overwrite --jsondir data/json
python -m ssvc.doctools --overwrite --datadir data

"""
import importlib
Expand Down
4 changes: 2 additions & 2 deletions src/ssvc/selection.py
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ def validate_values(cls, data):

def model_json_schema(cls, **kwargs):
schema = super().model_json_schema(**kwargs)
not_required = ["name", "description"]
not_required = ["name","definition"]
if "required" in schema and isinstance(schema["required"], list):
# remove description from required list if it exists
schema["required"] = [
Expand Down Expand Up @@ -330,7 +330,7 @@ def model_json_schema(cls, **kwargs):

non_required_fields = [
"name",
"description",
"definition",
"target_ids",
"decision_point_resources",
"references",
Expand Down