Skip to content

Commit 21ca15a

Browse files
Major updates to threatmodeling and bluepring schemas and their related schemas. Supersedes and closes #777.
Signed-off-by: Steve Springett <steve@springett.us>
1 parent 54d16af commit 21ca15a

9 files changed

Lines changed: 1581 additions & 681 deletions

schema/2.0/cyclonedx-2.0.schema.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,6 +79,9 @@
7979
"blueprints": {
8080
"$ref": "model/cyclonedx-blueprint-2.0.schema.json#/$defs/blueprints"
8181
},
82+
"profiles": {
83+
"$ref": "model/cyclonedx-profile-2.0.schema.json#/$defs/profiles"
84+
},
8285
"citations": {
8386
"$ref": "model/cyclonedx-citation-2.0.schema.json#/$defs/citations"
8487
},

schema/2.0/model/cyclonedx-blueprint-2.0.schema.json

Lines changed: 460 additions & 368 deletions
Large diffs are not rendered by default.

schema/2.0/model/cyclonedx-component-2.0.schema.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,14 @@
156156
"$ref": "cyclonedx-patent-2.0.schema.json#/$defs/patentAssertions",
157157
"title": "Component Patent(s)"
158158
},
159+
"requirementAssertions": {
160+
"$ref": "cyclonedx-requirement-2.0.schema.json#/$defs/requirementAssertions",
161+
"title": "Component Requirement(s)"
162+
},
163+
"useCaseAssertions": {
164+
"$ref": "cyclonedx-usecase-2.0.schema.json#/$defs/useCaseAssertions",
165+
"title": "Component Use Case(s)"
166+
},
159167
"cpe": {
160168
"type": "string",
161169
"title": "Common Platform Enumeration (CPE)",

schema/2.0/model/cyclonedx-data-2.0.schema.json

Lines changed: 527 additions & 194 deletions
Large diffs are not rendered by default.
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"$schema": "https://json-schema.org/draft/2020-12/schema",
3+
"$id": "https://cyclonedx.org/schema/2.0/model/cyclonedx-profile-2.0.schema.json",
4+
"type": "null",
5+
"title": "CycloneDX Profile Model",
6+
"$comment": "OWASP CycloneDX is an Ecma International standard (ECMA-424) developed in collaboration between the OWASP Foundation and Ecma Technical Committee 54 (TC54). The standard is published under a royalty-free patent policy. This JSON schema is the reference implementation and is licensed under the Apache License 2.0.",
7+
"$defs": {
8+
"profiles": {
9+
"type": "object",
10+
"title": "Profiles",
11+
"description": "A reusable, named characterization of how a subject behaves or is governed within a domain. Profiles separate characterization from identity: identity describes who or what the subject is; the profile describes the durable attributes that characterize it.",
12+
"additionalProperties": false,
13+
"properties": {
14+
"dataProfiles": {
15+
"$ref": "cyclonedx-data-2.0.schema.json#/$defs/dataProfiles"
16+
}
17+
}
18+
}
19+
}
20+
}

schema/2.0/model/cyclonedx-requirement-2.0.schema.json

Lines changed: 63 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"$id": "https://cyclonedx.org/schema/2.0/model/cyclonedx-requirement-2.0.schema.json",
44
"type": "null",
55
"title": "CycloneDX Engineering Requirement Model",
6-
"$comment" : "OWASP CycloneDX is an Ecma International standard (ECMA-424) developed in collaboration between the OWASP Foundation and Ecma Technical Committee 54 (TC54). The standard is published under a royalty-free patent policy. This JSON schema is the reference implementation and is licensed under the Apache License 2.0.",
6+
"$comment": "OWASP CycloneDX is an Ecma International standard (ECMA-424) developed in collaboration between the OWASP Foundation and Ecma Technical Committee 54 (TC54). The standard is published under a royalty-free patent policy. This JSON schema is the reference implementation and is licensed under the Apache License 2.0.",
77
"$defs": {
88
"requirements": {
99
"type": "array",
@@ -91,9 +91,9 @@
9191
}
9292
},
9393
"parent": {
94-
"type": "string",
94+
"$ref": "cyclonedx-common-2.0.schema.json#/$defs/refLinkType",
9595
"title": "Parent BOM Reference",
96-
"description": "The optional `bom-ref` to a parent requirement. This establishes a hierarchy of requirements."
96+
"description": "Optional reference using bom-link or bom-ref to a parent requirement. Establishes a hierarchy of requirements."
9797
},
9898
"rationale": {
9999
"type": "string",
@@ -274,6 +274,66 @@
274274
"description": "A description of the dependency relationship."
275275
}
276276
}
277+
},
278+
"requirementAssertions": {
279+
"type": "array",
280+
"title": "Requirement Assertions",
281+
"description": "A list of assertions describing how a component relates to specific requirements.",
282+
"uniqueItems": true,
283+
"items": {
284+
"type": "object",
285+
"title": "Requirement Assertion",
286+
"description": "An assertion linking one or more requirements to a component, specifying the nature of the relationship.",
287+
"required": [
288+
"assertionType",
289+
"requirementRefs"
290+
],
291+
"additionalProperties": false,
292+
"properties": {
293+
"bom-ref": {
294+
"$ref": "cyclonedx-common-2.0.schema.json#/$defs/refType",
295+
"title": "BOM Reference",
296+
"description": "An identifier which can be used to reference the assertion elsewhere in the BOM. Every `bom-ref` must be unique within the BOM."
297+
},
298+
"assertionType": {
299+
"type": "string",
300+
"title": "Assertion Type",
301+
"description": "The type of assertion being made about the relationship between the component and the requirement.",
302+
"enum": [
303+
"conflicts",
304+
"not-applicable",
305+
"not-assessed",
306+
"other",
307+
"partially-satisfies",
308+
"satisfies",
309+
"violates"
310+
],
311+
"meta:enum": {
312+
"conflicts": "The component is in tension with the requirement but a definitive determination of violation has not been made. This may indicate partial incompatibility, competing constraints, or an unresolved evaluation.",
313+
"not-applicable": "The requirement does not pertain to this component. The evaluator has reviewed the requirement and determined it is irrelevant.",
314+
"not-assessed": "The relationship between the component and the requirement has not yet been evaluated.",
315+
"other": "A relationship that does not fit into the other predefined assertion types.",
316+
"partially-satisfies": "The component partially meets the requirement but does not fully satisfy all of its conditions or acceptance criteria.",
317+
"satisfies": "The component fully satisfies the requirement, meeting all of its conditions and acceptance criteria.",
318+
"violates": "The component has been evaluated and conclusively determined to not meet the requirement, breaching one or more of its conditions or acceptance criteria."
319+
}
320+
},
321+
"requirementRefs": {
322+
"type": "array",
323+
"title": "Requirement References",
324+
"description": "A list of BOM references linking to requirement objects defined in the BOM.",
325+
"uniqueItems": true,
326+
"items": {
327+
"$ref": "cyclonedx-common-2.0.schema.json#/$defs/refLinkType"
328+
}
329+
},
330+
"description": {
331+
"type": "string",
332+
"title": "Description",
333+
"description": "Additional context or clarification regarding the assertion."
334+
}
335+
}
336+
}
277337
}
278338
}
279339
}

0 commit comments

Comments
 (0)