forked from oasis-tcs/csaf
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- addresses parts of oasis-tcs#774, oasis-tcs#781, oasis-tcs#341 - improve wording of 6.1.42 - move tests to testfiles - add invalid examples - add valid examples - adapt test schema
- Loading branch information
1 parent
8a4229c
commit f221842
Showing
7 changed files
with
263 additions
and
24 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
46 changes: 46 additions & 0 deletions
46
csaf_2.1/test/validator/data/mandatory/oasis_csaf_tc-csaf_2_1-2024-6-1-42-01.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
{ | ||
"$schema": "https://docs.oasis-open.org/csaf/csaf/v2.1/csaf_json_schema.json", | ||
"document": { | ||
"category": "csaf_base", | ||
"csaf_version": "2.1", | ||
"distribution": { | ||
"tlp": { | ||
"label": "CLEAR" | ||
} | ||
}, | ||
"publisher": { | ||
"category": "other", | ||
"name": "OASIS CSAF TC", | ||
"namespace": "https://csaf.io" | ||
}, | ||
"title": "Mandatory test: PURL Qualifiers (failing example 1)", | ||
"tracking": { | ||
"current_release_date": "2024-01-24T10:00:00.000Z", | ||
"id": "OASIS_CSAF_TC-CSAF_2.1-2024-6-1-42-01", | ||
"initial_release_date": "2024-01-24T10:00:00.000Z", | ||
"revision_history": [ | ||
{ | ||
"date": "2024-01-24T10:00:00.000Z", | ||
"number": "1", | ||
"summary": "Initial version." | ||
} | ||
], | ||
"status": "final", | ||
"version": "1" | ||
} | ||
}, | ||
"product_tree": { | ||
"full_product_names": [ | ||
{ | ||
"name": "Product A", | ||
"product_id": "CSAFPID-9080700", | ||
"product_identification_helper": { | ||
"purls": [ | ||
"pkg:maven/com.example/logging@1.3.4", | ||
"pkg:maven/com.example/audit@1.3.4" | ||
] | ||
} | ||
} | ||
] | ||
} | ||
} |
63 changes: 63 additions & 0 deletions
63
csaf_2.1/test/validator/data/mandatory/oasis_csaf_tc-csaf_2_1-2024-6-1-42-02.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
{ | ||
"$schema": "https://docs.oasis-open.org/csaf/csaf/v2.1/csaf_json_schema.json", | ||
"document": { | ||
"category": "csaf_base", | ||
"csaf_version": "2.1", | ||
"distribution": { | ||
"tlp": { | ||
"label": "CLEAR" | ||
} | ||
}, | ||
"publisher": { | ||
"category": "other", | ||
"name": "OASIS CSAF TC", | ||
"namespace": "https://csaf.io" | ||
}, | ||
"title": "Mandatory test: PURL Qualifiers (failing example 2)", | ||
"tracking": { | ||
"current_release_date": "2024-01-24T10:00:00.000Z", | ||
"id": "OASIS_CSAF_TC-CSAF_2.1-2024-6-1-42-02", | ||
"initial_release_date": "2024-01-24T10:00:00.000Z", | ||
"revision_history": [ | ||
{ | ||
"date": "2024-01-24T10:00:00.000Z", | ||
"number": "1", | ||
"summary": "Initial version." | ||
} | ||
], | ||
"status": "final", | ||
"version": "1" | ||
} | ||
}, | ||
"product_tree": { | ||
"branches": [ | ||
{ | ||
"category": "vendor", | ||
"name": "Example Company", | ||
"branches": [ | ||
{ | ||
"category": "product_name", | ||
"name": "Product A", | ||
"branches": [ | ||
{ | ||
"category": "product_version", | ||
"name": "1.3.4", | ||
"product": { | ||
"product_id": "CSAFPID-9080700", | ||
"name": "Example Company Product A 1.3.4", | ||
"product_identification_helper": { | ||
"purls": [ | ||
"pkg:maven/com.example/product-A@1.3.4?repository_url=https://registry.example.com", | ||
"pkg:maven/com.example/product-A@1.3.4?repository_url=https://index.example.com", | ||
"pkg:maven/com.example/product-A?repository_url=https://index.example.com" | ||
] | ||
} | ||
} | ||
} | ||
] | ||
} | ||
] | ||
} | ||
] | ||
} | ||
} |
62 changes: 62 additions & 0 deletions
62
csaf_2.1/test/validator/data/mandatory/oasis_csaf_tc-csaf_2_1-2024-6-1-42-11.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
{ | ||
"$schema": "https://docs.oasis-open.org/csaf/csaf/v2.1/csaf_json_schema.json", | ||
"document": { | ||
"category": "csaf_base", | ||
"csaf_version": "2.1", | ||
"distribution": { | ||
"tlp": { | ||
"label": "CLEAR" | ||
} | ||
}, | ||
"publisher": { | ||
"category": "other", | ||
"name": "OASIS CSAF TC", | ||
"namespace": "https://csaf.io" | ||
}, | ||
"title": "Mandatory test: PURL Qualifiers (valid example 1)", | ||
"tracking": { | ||
"current_release_date": "2024-01-24T10:00:00.000Z", | ||
"id": "OASIS_CSAF_TC-CSAF_2.1-2024-6-1-42-11", | ||
"initial_release_date": "2024-01-24T10:00:00.000Z", | ||
"revision_history": [ | ||
{ | ||
"date": "2024-01-24T10:00:00.000Z", | ||
"number": "1", | ||
"summary": "Initial version." | ||
} | ||
], | ||
"status": "final", | ||
"version": "1" | ||
} | ||
}, | ||
"product_tree": { | ||
"branches": [ | ||
{ | ||
"category": "vendor", | ||
"name": "Example Company", | ||
"branches": [ | ||
{ | ||
"category": "product_name", | ||
"name": "Product A", | ||
"branches": [ | ||
{ | ||
"category": "product_version", | ||
"name": "1.3.4", | ||
"product": { | ||
"product_id": "CSAFPID-9080700", | ||
"name": "Example Company Product A 1.3.4", | ||
"product_identification_helper": { | ||
"purls": [ | ||
"pkg:maven/com.example/product-A@1.3.4?repository_url=https://registry.example.com", | ||
"pkg:maven/com.example/product-A@1.3.4?repository_url=https://index.example.com" | ||
] | ||
} | ||
} | ||
} | ||
] | ||
} | ||
] | ||
} | ||
] | ||
} | ||
} |
63 changes: 63 additions & 0 deletions
63
csaf_2.1/test/validator/data/mandatory/oasis_csaf_tc-csaf_2_1-2024-6-1-42-12.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
{ | ||
"$schema": "https://docs.oasis-open.org/csaf/csaf/v2.1/csaf_json_schema.json", | ||
"document": { | ||
"category": "csaf_base", | ||
"csaf_version": "2.1", | ||
"distribution": { | ||
"tlp": { | ||
"label": "CLEAR" | ||
} | ||
}, | ||
"publisher": { | ||
"category": "other", | ||
"name": "OASIS CSAF TC", | ||
"namespace": "https://csaf.io" | ||
}, | ||
"title": "Mandatory test: PURL Qualifiers (valid example 2)", | ||
"tracking": { | ||
"current_release_date": "2024-01-24T10:00:00.000Z", | ||
"id": "OASIS_CSAF_TC-CSAF_2.1-2024-6-1-42-12", | ||
"initial_release_date": "2024-01-24T10:00:00.000Z", | ||
"revision_history": [ | ||
{ | ||
"date": "2024-01-24T10:00:00.000Z", | ||
"number": "1", | ||
"summary": "Initial version." | ||
} | ||
], | ||
"status": "final", | ||
"version": "1" | ||
} | ||
}, | ||
"product_tree": { | ||
"branches": [ | ||
{ | ||
"category": "vendor", | ||
"name": "Example Company", | ||
"branches": [ | ||
{ | ||
"category": "product_name", | ||
"name": "Product A", | ||
"branches": [ | ||
{ | ||
"category": "product_version", | ||
"name": "1.3.4", | ||
"product": { | ||
"product_id": "CSAFPID-9080700", | ||
"name": "Example Company Product A 1.3.4", | ||
"product_identification_helper": { | ||
"purls": [ | ||
"pkg:maven/com.example/product-A@1.3.4", | ||
"pkg:maven/com.example/product-A@1.3.4?classifier=sources", | ||
"pkg:maven/com.example/product-A@1.3.4?classifier=javadoc" | ||
] | ||
} | ||
} | ||
} | ||
] | ||
} | ||
] | ||
} | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters