@mitre/hdf-schema 3.7.2 → 3.8.0-next.42532249979.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -0
- package/dist/go/hdf.go +348 -181
- package/dist/helpers.d.ts +7 -5
- package/dist/helpers.js +1 -0
- package/dist/index.d.ts +12 -0
- package/dist/index.js +28 -28
- package/dist/schemas/hdf-amendments.schema.json +414 -62
- package/dist/schemas/hdf-baseline.schema.json +419 -67
- package/dist/schemas/hdf-comparison.schema.json +730 -153
- package/dist/schemas/hdf-evidence-package.schema.json +418 -65
- package/dist/schemas/hdf-plan.schema.json +420 -68
- package/dist/schemas/hdf-requirement-change-event.schema.json +486 -140
- package/dist/schemas/hdf-results.schema.json +472 -126
- package/dist/schemas/hdf-system.schema.json +435 -83
- package/dist/ts/hdf.d.ts +218 -26
- package/dist/ts/hdf.js +18 -2
- package/dist/ts/hdf.ts +219 -20
- package/package.json +3 -3
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
-
"$id": "https://mitre.github.io/hdf-libs/schemas/hdf-plan/v3.
|
|
3
|
+
"$id": "https://mitre.github.io/hdf-libs/schemas/hdf-plan/v3.8.0",
|
|
4
4
|
"title": "HDF Plan",
|
|
5
5
|
"description": "Defines an assessment plan — what baselines to run against which targets, with resolved inputs and scheduling. Maps to OSCAL Assessment Plan.",
|
|
6
6
|
"type": "object",
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
"externalReferences": {
|
|
14
14
|
"type": "array",
|
|
15
15
|
"items": {
|
|
16
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
16
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/External_Reference"
|
|
17
17
|
},
|
|
18
18
|
"description": "Optional references to external artifacts relevant to this assessment plan (CTI/STIX, advisories, methodology docs, or any URI-addressable artifact). Inert context; see External_Reference."
|
|
19
19
|
},
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"description": "Human-readable plan name. Example: 'Portal Monthly Assessment'."
|
|
28
28
|
},
|
|
29
29
|
"type": {
|
|
30
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/plan/v3.
|
|
30
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/plan/v3.8.0#/$defs/Plan_Type",
|
|
31
31
|
"description": "The type of assessment plan."
|
|
32
32
|
},
|
|
33
33
|
"description": {
|
|
@@ -43,12 +43,12 @@
|
|
|
43
43
|
"type": "array",
|
|
44
44
|
"minItems": 1,
|
|
45
45
|
"items": {
|
|
46
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/plan/v3.
|
|
46
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/plan/v3.8.0#/$defs/Assessment"
|
|
47
47
|
},
|
|
48
48
|
"description": "The assessments to perform. Each assessment pairs a baseline with targets and resolved inputs."
|
|
49
49
|
},
|
|
50
50
|
"schedule": {
|
|
51
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/plan/v3.
|
|
51
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/plan/v3.8.0#/$defs/Schedule",
|
|
52
52
|
"description": "Optional scheduling configuration for recurring assessments."
|
|
53
53
|
},
|
|
54
54
|
"labels": {
|
|
@@ -59,7 +59,7 @@
|
|
|
59
59
|
"description": "Optional key-value labels for grouping and querying plans."
|
|
60
60
|
},
|
|
61
61
|
"integrity": {
|
|
62
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/extensions/v3.
|
|
62
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/extensions/v3.8.0#/$defs/Integrity",
|
|
63
63
|
"description": "Cryptographic integrity information for verifying this plan document has not been tampered with."
|
|
64
64
|
},
|
|
65
65
|
"version": {
|
|
@@ -67,8 +67,12 @@
|
|
|
67
67
|
"description": "Version of this plan document."
|
|
68
68
|
},
|
|
69
69
|
"generator": {
|
|
70
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/extensions/v3.
|
|
70
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/extensions/v3.8.0#/$defs/Generator",
|
|
71
71
|
"description": "Information about the tool that generated this plan."
|
|
72
|
+
},
|
|
73
|
+
"extensions": {
|
|
74
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/extensions/v3.8.0#/$defs/Extensions",
|
|
75
|
+
"description": "Producer data outside the HDF model, and the pre-converted source artifact(s) this plan was converted from."
|
|
72
76
|
}
|
|
73
77
|
},
|
|
74
78
|
"examples": [
|
|
@@ -101,16 +105,16 @@
|
|
|
101
105
|
}
|
|
102
106
|
],
|
|
103
107
|
"$defs": {
|
|
104
|
-
"https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
108
|
+
"https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0": {
|
|
105
109
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
106
|
-
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
110
|
+
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0",
|
|
107
111
|
"title": "HDF Common Primitives",
|
|
108
112
|
"description": "Shared building blocks used by hdf-results and hdf-baseline schemas.",
|
|
109
113
|
"$defs": {
|
|
110
114
|
"External_Reference": {
|
|
111
115
|
"type": "object",
|
|
112
116
|
"title": "External Reference",
|
|
113
|
-
"description": "A generalized reference to any external artifact by identity and/or location, modeled on the STIX 2.1 `external_references` common property.\n\nPurpose-agnostic: cite a CVE, an ATT&CK technique, a STIX bundle/object, a BOM, a runbook, or any vendor artifact — including kinds with no dedicated HDF reference category.\n\n`sourceName` names the system; `externalId` cites by id within that system; `href` locates it. `sourceName` + `externalId` is equivalently a URN (`urn:<sourceName>:<externalId>`, RFC 8141), so the by-identity and by-location forms stay interconvertible.\n\nA reference is inert context: it overrides nothing, so it carries only lightweight optional `addedBy`/`addedAt` attribution, never override machinery.",
|
|
117
|
+
"description": "A generalized reference to any external artifact by identity and/or location, modeled on the STIX 2.1 `external_references` common property.\n\nPurpose-agnostic: cite a CVE, an ATT&CK technique, a STIX bundle/object, a BOM, a runbook, or any vendor artifact — including kinds with no dedicated HDF reference category.\n\n`sourceName` names the system; `externalId` cites by id within that system; `href` locates it. `sourceName` + `externalId` is equivalently a URN (`urn:<sourceName>:<externalId>`, RFC 8141), so the by-identity and by-location forms stay interconvertible.\n\nAn entry may also carry the artifact itself rather than point at it: `document` for a JSON object, `content` + `encoding` for anything else. Embedding satisfies the at-least-one rule on its own, so an artifact with no meaningful public location needs no synthetic `href`.\n\nA reference is inert context: it overrides nothing, so it carries only lightweight optional `addedBy`/`addedAt` attribution, never override machinery.",
|
|
114
118
|
"required": [
|
|
115
119
|
"sourceName"
|
|
116
120
|
],
|
|
@@ -129,6 +133,42 @@
|
|
|
129
133
|
"required": [
|
|
130
134
|
"description"
|
|
131
135
|
]
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
"required": [
|
|
139
|
+
"content"
|
|
140
|
+
]
|
|
141
|
+
},
|
|
142
|
+
{
|
|
143
|
+
"required": [
|
|
144
|
+
"document"
|
|
145
|
+
]
|
|
146
|
+
}
|
|
147
|
+
],
|
|
148
|
+
"allOf": [
|
|
149
|
+
{
|
|
150
|
+
"if": {
|
|
151
|
+
"required": [
|
|
152
|
+
"content"
|
|
153
|
+
]
|
|
154
|
+
},
|
|
155
|
+
"then": {
|
|
156
|
+
"required": [
|
|
157
|
+
"encoding"
|
|
158
|
+
]
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
"if": {
|
|
163
|
+
"required": [
|
|
164
|
+
"encoding"
|
|
165
|
+
]
|
|
166
|
+
},
|
|
167
|
+
"then": {
|
|
168
|
+
"required": [
|
|
169
|
+
"content"
|
|
170
|
+
]
|
|
171
|
+
}
|
|
132
172
|
}
|
|
133
173
|
],
|
|
134
174
|
"properties": {
|
|
@@ -144,7 +184,7 @@
|
|
|
144
184
|
"href": {
|
|
145
185
|
"type": "string",
|
|
146
186
|
"format": "uri-reference",
|
|
147
|
-
"description": "Location of the artifact. `uri-reference` (not `uri`) so a bare internal `#fragment`/`#uuid` reference is expressible alongside absolute URLs.
|
|
187
|
+
"description": "Location of the artifact. `uri-reference` (not `uri`) so a bare internal `#fragment`/`#uuid` reference is expressible alongside absolute URLs. Set it only when the location is meaningful to a reader — never a producer's local filesystem path."
|
|
148
188
|
},
|
|
149
189
|
"description": {
|
|
150
190
|
"type": "string",
|
|
@@ -156,11 +196,11 @@
|
|
|
156
196
|
},
|
|
157
197
|
"mediaType": {
|
|
158
198
|
"type": "string",
|
|
159
|
-
"description": "IANA media type of the
|
|
199
|
+
"description": "IANA media type of the artifact (RFC 6838), e.g., 'application/json', 'application/xml', 'text/csv'. Applies both to an artifact retrievable at `href` and to one embedded here in `content` or `document`."
|
|
160
200
|
},
|
|
161
201
|
"checksum": {
|
|
162
202
|
"$ref": "#/$defs/Checksum",
|
|
163
|
-
"description": "Integrity hash of the
|
|
203
|
+
"description": "Integrity hash of the artifact. Reuses the HDF `Checksum` primitive (not STIX `hashes`). Applies both to an artifact retrievable at `href` and to one embedded here in `content` or `document` — beside embedded bytes it is what makes the copy verifiable rather than merely present."
|
|
164
204
|
},
|
|
165
205
|
"addedBy": {
|
|
166
206
|
"$ref": "#/$defs/Identity",
|
|
@@ -179,11 +219,24 @@
|
|
|
179
219
|
"document": {
|
|
180
220
|
"type": "object",
|
|
181
221
|
"additionalProperties": true,
|
|
182
|
-
"description": "Optional lossless embedded copy of the referenced artifact — the raw STIX object, EPSS record, advisory, or annotation payload — preserved verbatim.\n\nComposes with `href`/`externalId` (which point at the artifact) and `checksum` (which ties the copy to the source): a single entry can both point and embed.\n\nHDF stays payload-agnostic — the content is carried untouched, never normalized into HDF fields — so this does not duplicate the source ontology (e.g. STIX rides here unchanged)."
|
|
222
|
+
"description": "Optional lossless embedded copy of the referenced artifact as a JSON object — the raw STIX object, EPSS record, advisory, or annotation payload — preserved verbatim.\n\nJSON objects only. An artifact that is not a JSON object (XML, CSV, NDJSON, plain text, a JSON array, or bytes that are not text at all) embeds through `content` + `encoding` instead.\n\nComposes with `href`/`externalId` (which point at the artifact) and `checksum` (which ties the copy to the source): a single entry can both point and embed.\n\nHDF stays payload-agnostic — the content is carried untouched, never normalized into HDF fields — so this does not duplicate the source ontology (e.g. STIX rides here unchanged)."
|
|
223
|
+
},
|
|
224
|
+
"content": {
|
|
225
|
+
"type": "string",
|
|
226
|
+
"description": "Optional lossless embedded copy of the artifact's bytes as a string, for artifacts `document` cannot hold: XML, CSV, NDJSON, plain text, a JSON array, or bytes that are not valid UTF-8 text at all.\n\n`encoding` states how to read it back and is required alongside it. Set `mediaType` so a consumer knows what the bytes are, and `checksum` so the copy can be verified against the source.\n\nCarried verbatim — never reformatted, re-indented, or re-serialized."
|
|
227
|
+
},
|
|
228
|
+
"encoding": {
|
|
229
|
+
"type": "string",
|
|
230
|
+
"title": "External Reference Encoding",
|
|
231
|
+
"enum": [
|
|
232
|
+
"utf-8",
|
|
233
|
+
"base64"
|
|
234
|
+
],
|
|
235
|
+
"description": "How to read `content` back into the artifact's bytes. 'utf-8' for text (XML, CSV, NDJSON, plain text, JavaScript-wrapped JSON); 'base64' for anything that is not valid UTF-8 text.\n\nRequired whenever `content` is present, and meaningless without it — an embedded copy whose encoding a consumer has to guess is not lossless."
|
|
183
236
|
}
|
|
184
237
|
},
|
|
185
238
|
"unevaluatedProperties": false,
|
|
186
|
-
"$comment": "Examples, in order: 1) By-identity: cite a CVE by its id in the 'cve' system without a URL — equivalently urn:cve:CVE-2021-44228; 2) By-identity AND by-locator together (anyOf, not oneOf) — an ATT&CK technique cited by id with its canonical URL; 3) By-locator to a retrievable STIX bundle, with integrity hash, media type, and attribution; 4) Enrichment envelope: a STIX threat-intel object embedded losslessly in `document` and classified via `kind`, cited by id and pointed at by href — the pointer and the embedded copy compose. The payload rides verbatim; HDF does not normalize STIX fields.",
|
|
239
|
+
"$comment": "Examples, in order: 1) By-identity: cite a CVE by its id in the 'cve' system without a URL — equivalently urn:cve:CVE-2021-44228; 2) By-identity AND by-locator together (anyOf, not oneOf) — an ATT&CK technique cited by id with its canonical URL; 3) By-locator to a retrievable STIX bundle, with integrity hash, media type, and attribution; 4) Enrichment envelope: a STIX threat-intel object embedded losslessly in `document` and classified via `kind`, cited by id and pointed at by href — the pointer and the embedded copy compose. The payload rides verbatim; HDF does not normalize STIX fields; 5) Embed-only, text: an XCCDF results file carried in `content` as utf-8 with its media type and checksum, and no `href` at all — the artifact was read from a local file whose path means nothing to a reader; 6) Embed-only, non-text: a Fortify FPR (a zip) carried in `content` as base64, the case `document` and utf-8 both fail.",
|
|
187
240
|
"examples": [
|
|
188
241
|
{
|
|
189
242
|
"sourceName": "cve",
|
|
@@ -229,6 +282,28 @@
|
|
|
229
282
|
}
|
|
230
283
|
]
|
|
231
284
|
}
|
|
285
|
+
},
|
|
286
|
+
{
|
|
287
|
+
"sourceName": "openscap",
|
|
288
|
+
"rel": "raw-source",
|
|
289
|
+
"mediaType": "application/xml",
|
|
290
|
+
"encoding": "utf-8",
|
|
291
|
+
"content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<Benchmark xmlns=\"http://checklists.nist.gov/xccdf/1.2\" id=\"xccdf_org.ssgproject.content_benchmark_RHEL-9\">\n <TestResult id=\"xccdf_org.open-scap_testresult_default-profile\" start-time=\"2026-09-27T12:00:00+00:00\" end-time=\"2026-09-27T12:04:11+00:00\">\n <rule-result idref=\"xccdf_org.ssgproject.content_rule_sshd_disable_root_login\" severity=\"medium\">\n <result>fail</result>\n </rule-result>\n </TestResult>\n</Benchmark>",
|
|
292
|
+
"checksum": {
|
|
293
|
+
"algorithm": "sha256",
|
|
294
|
+
"value": "713b3ee32af5c14ac93e519b5025d760983607143dba3a0438f68667923beda1"
|
|
295
|
+
}
|
|
296
|
+
},
|
|
297
|
+
{
|
|
298
|
+
"sourceName": "fortify",
|
|
299
|
+
"rel": "raw-source",
|
|
300
|
+
"mediaType": "application/zip",
|
|
301
|
+
"encoding": "base64",
|
|
302
|
+
"content": "UEsDBBQAAAAIAEVnPF20b/JoHgAAABwAAAAKAAAAYXVkaXQuZnZkbLOxr8jNUShLLSrOzM+zVTLUM1Cyt7NxC3Px0bcDAFBLAQIUAxQAAAAIAEVnPF20b/JoHgAAABwAAAAKAAAAAAAAAAAAAACAAQAAAABhdWRpdC5mdmRsUEsFBgAAAAABAAEAOAAAAEYAAAAAAA==",
|
|
303
|
+
"checksum": {
|
|
304
|
+
"algorithm": "sha256",
|
|
305
|
+
"value": "c7e4cefceecb83511ae6174c7d22584061671dee6dc5f27243503b47532a66b1"
|
|
306
|
+
}
|
|
232
307
|
}
|
|
233
308
|
]
|
|
234
309
|
},
|
|
@@ -240,7 +315,7 @@
|
|
|
240
315
|
"sha512",
|
|
241
316
|
"blake3"
|
|
242
317
|
],
|
|
243
|
-
"description": "
|
|
318
|
+
"description": "Cryptographic hash algorithms a checksum or integrity record may name. blake3 covers container-image and other artifact digests that use it. HDF tooling verifies every algorithm in this enum, so any of them may be recorded where the checksum needs to be verifiable.",
|
|
244
319
|
"title": "Hash Algorithm"
|
|
245
320
|
},
|
|
246
321
|
"Requirement_Group": {
|
|
@@ -398,7 +473,33 @@
|
|
|
398
473
|
}
|
|
399
474
|
],
|
|
400
475
|
"description": "A reference to an external document.",
|
|
401
|
-
"title": "Reference"
|
|
476
|
+
"title": "Reference",
|
|
477
|
+
"unevaluatedProperties": false,
|
|
478
|
+
"$comment": "Examples, in order: 1) By-locator: a plain URL, the commonest form by far in practice; 2) By-name: a human-meaningful citation with no locator, as InSpec's `ref 'title'` emits; 3) Both together, since this is an anyOf rather than a oneOf; 4) The ref-as-array form, whose items are deliberately open so a source format's own reference record can be carried verbatim — XCCDF's DPMS target identifiers reach HDF this way; 5) uri, accepted as a synonym of url for documents that spell it that way. The object itself is CLOSED: a member none of the three branches declares is rejected. The openness that matters here is one level down, on the items of the ref array, and it is declared there explicitly. This primitive predates External_Reference, which is the STIX-aligned type a new converter should reach for; refs survives because it is InSpec-inherited and HDF consumes InSpec output.",
|
|
479
|
+
"examples": [
|
|
480
|
+
{
|
|
481
|
+
"url": "https://nvd.nist.gov/vuln/detail/CVE-2021-44228"
|
|
482
|
+
},
|
|
483
|
+
{
|
|
484
|
+
"ref": "NIST SP 800-53 Rev 5, AC-6"
|
|
485
|
+
},
|
|
486
|
+
{
|
|
487
|
+
"ref": "CIS Benchmark for RHEL 9, 1.1.1",
|
|
488
|
+
"url": "https://www.cisecurity.org/benchmark/red_hat_linux"
|
|
489
|
+
},
|
|
490
|
+
{
|
|
491
|
+
"ref": [
|
|
492
|
+
{
|
|
493
|
+
"identifier": "2921",
|
|
494
|
+
"publisher": "DISA",
|
|
495
|
+
"type": "DPMS Target"
|
|
496
|
+
}
|
|
497
|
+
]
|
|
498
|
+
},
|
|
499
|
+
{
|
|
500
|
+
"uri": "https://attack.mitre.org/techniques/T1059/"
|
|
501
|
+
}
|
|
502
|
+
]
|
|
402
503
|
},
|
|
403
504
|
"Source_Location": {
|
|
404
505
|
"type": "object",
|
|
@@ -1212,9 +1313,9 @@
|
|
|
1212
1313
|
}
|
|
1213
1314
|
}
|
|
1214
1315
|
},
|
|
1215
|
-
"https://mitre.github.io/hdf-libs/schemas/primitives/plan/v3.
|
|
1316
|
+
"https://mitre.github.io/hdf-libs/schemas/primitives/plan/v3.8.0": {
|
|
1216
1317
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1217
|
-
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/plan/v3.
|
|
1318
|
+
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/plan/v3.8.0",
|
|
1218
1319
|
"title": "HDF Plan Primitives",
|
|
1219
1320
|
"description": "Types for defining assessment plans — what to scan, how to configure it, and when to run.",
|
|
1220
1321
|
"$defs": {
|
|
@@ -1262,7 +1363,7 @@
|
|
|
1262
1363
|
"description": "componentId of the system component this assessment targets. Use for direct component binding. Alternative to targetSelector."
|
|
1263
1364
|
},
|
|
1264
1365
|
"targetSelector": {
|
|
1265
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/system/v3.
|
|
1366
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/system/v3.8.0#/$defs/Target_Selector",
|
|
1266
1367
|
"description": "Label selector to match targets for this assessment. Overrides the system component's targetSelector if provided."
|
|
1267
1368
|
},
|
|
1268
1369
|
"inputs": {
|
|
@@ -1344,9 +1445,9 @@
|
|
|
1344
1445
|
}
|
|
1345
1446
|
}
|
|
1346
1447
|
},
|
|
1347
|
-
"https://mitre.github.io/hdf-libs/schemas/primitives/system/v3.
|
|
1448
|
+
"https://mitre.github.io/hdf-libs/schemas/primitives/system/v3.8.0": {
|
|
1348
1449
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1349
|
-
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/system/v3.
|
|
1450
|
+
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/system/v3.8.0",
|
|
1350
1451
|
"title": "HDF System Primitives",
|
|
1351
1452
|
"description": "Types for describing system architecture, authorization boundaries, and components.",
|
|
1352
1453
|
"$defs": {
|
|
@@ -1397,7 +1498,7 @@
|
|
|
1397
1498
|
"description": "Rationale for why this override is needed."
|
|
1398
1499
|
},
|
|
1399
1500
|
"approvedBy": {
|
|
1400
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
1501
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Identity",
|
|
1401
1502
|
"description": "Identity of the person or system that approved this override."
|
|
1402
1503
|
}
|
|
1403
1504
|
},
|
|
@@ -1479,12 +1580,183 @@
|
|
|
1479
1580
|
}
|
|
1480
1581
|
}
|
|
1481
1582
|
},
|
|
1482
|
-
"https://mitre.github.io/hdf-libs/schemas/primitives/extensions/v3.
|
|
1583
|
+
"https://mitre.github.io/hdf-libs/schemas/primitives/extensions/v3.8.0": {
|
|
1483
1584
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1484
|
-
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/extensions/v3.
|
|
1585
|
+
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/extensions/v3.8.0",
|
|
1485
1586
|
"title": "HDF Extension Primitives",
|
|
1486
|
-
"description": "Extension types for waivers, attestations, generators, and
|
|
1587
|
+
"description": "Extension types for waivers, attestations, generators, integrity, and the document-level extensions carrier.",
|
|
1487
1588
|
"$defs": {
|
|
1589
|
+
"Raw_Source_Artifact": {
|
|
1590
|
+
"allOf": [
|
|
1591
|
+
{
|
|
1592
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/External_Reference"
|
|
1593
|
+
},
|
|
1594
|
+
{
|
|
1595
|
+
"not": {
|
|
1596
|
+
"required": [
|
|
1597
|
+
"document"
|
|
1598
|
+
]
|
|
1599
|
+
}
|
|
1600
|
+
},
|
|
1601
|
+
{
|
|
1602
|
+
"if": {
|
|
1603
|
+
"required": [
|
|
1604
|
+
"content"
|
|
1605
|
+
]
|
|
1606
|
+
},
|
|
1607
|
+
"then": {
|
|
1608
|
+
"required": [
|
|
1609
|
+
"encoding",
|
|
1610
|
+
"mediaType"
|
|
1611
|
+
]
|
|
1612
|
+
}
|
|
1613
|
+
}
|
|
1614
|
+
],
|
|
1615
|
+
"description": "One artifact exactly as a converter received it, before conversion.\n\nAn External_Reference used for a single purpose, so the same primitive both points and embeds: `sourceName` names the producing tool; `content` + `encoding` carry the bytes; `checksum` is of the exact bytes the converter read; `rel` is 'raw-source'; `href` appears only when the caller supplied a location that means something to a reader, never a producer's local filesystem path.\n\nBYTES, NOT A PARSED COPY. `document` is forbidden here, enforced by the schema rather than described: it holds a parsed JSON object, so embedding through it discards the original whitespace, key order, duplicate keys and trailing bytes — which makes the artifact unreconstructable and the checksum unverifiable against what is stored. A JSON input carries as a `content` string like every other input. This is deliberately stricter than HDF v2, whose `passthrough.raw` held a parsed structure in every converter but one, and which for XML inputs stored a reshaped object whose keys could collide.\n\n`mediaType` is REQUIRED on an entry that embeds — bytes whose type a consumer has to infer are not carriage. It is derived from the converter's declared input family (json → application/json, xml → application/xml, text → text/plain) and overridden by converters that know their bytes more precisely (CSV, NDJSON, JavaScript-wrapped JSON).\n\nAn entry that only points at a location may omit `mediaType`, `content` and `encoding`.",
|
|
1616
|
+
"$comment": "Examples, in order: 1) JSON input embedded as a utf-8 `content` string — the common case, and note it is NOT a parsed object; 2) XML input, which `document` never could have held; 3) CSV input, where `mediaType` overrides the 'text' input family's derived text/plain; 4) non-text input (a Fortify FPR zip) embedded as base64; 5) by-reference only: a scan retrievable at a meaningful URL, with no embedded copy and therefore no required mediaType, encoding or content.",
|
|
1617
|
+
"examples": [
|
|
1618
|
+
{
|
|
1619
|
+
"sourceName": "grype",
|
|
1620
|
+
"rel": "raw-source",
|
|
1621
|
+
"mediaType": "application/json",
|
|
1622
|
+
"encoding": "utf-8",
|
|
1623
|
+
"content": "{\"matches\":[{\"vulnerability\":{\"id\":\"CVE-2021-36159\",\"severity\":\"Critical\"}}]}",
|
|
1624
|
+
"checksum": {
|
|
1625
|
+
"algorithm": "sha256",
|
|
1626
|
+
"value": "4b33be77f104d6ee323ff2c945d1c3f9a151606b2d263ea7932716844c75920c"
|
|
1627
|
+
}
|
|
1628
|
+
},
|
|
1629
|
+
{
|
|
1630
|
+
"sourceName": "openscap",
|
|
1631
|
+
"rel": "raw-source",
|
|
1632
|
+
"mediaType": "application/xml",
|
|
1633
|
+
"encoding": "utf-8",
|
|
1634
|
+
"content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<Benchmark xmlns=\"http://checklists.nist.gov/xccdf/1.2\" id=\"xccdf_org.ssgproject.content_benchmark_RHEL-9\">\n <TestResult id=\"xccdf_org.open-scap_testresult_default-profile\" start-time=\"2026-09-27T12:00:00+00:00\" end-time=\"2026-09-27T12:04:11+00:00\">\n <rule-result idref=\"xccdf_org.ssgproject.content_rule_sshd_disable_root_login\" severity=\"medium\">\n <result>fail</result>\n </rule-result>\n </TestResult>\n</Benchmark>",
|
|
1635
|
+
"checksum": {
|
|
1636
|
+
"algorithm": "sha256",
|
|
1637
|
+
"value": "713b3ee32af5c14ac93e519b5025d760983607143dba3a0438f68667923beda1"
|
|
1638
|
+
}
|
|
1639
|
+
},
|
|
1640
|
+
{
|
|
1641
|
+
"sourceName": "prisma",
|
|
1642
|
+
"rel": "raw-source",
|
|
1643
|
+
"mediaType": "text/csv",
|
|
1644
|
+
"encoding": "utf-8",
|
|
1645
|
+
"content": "Hostname,Distro,CVE ID,Compliance ID,Type,Severity,Packages,Source Package,Package Version\nhost-01,Ubuntu 22.04,CVE-2021-36159,,image,critical,apk-tools,apk-tools,2.12.5-r1\n",
|
|
1646
|
+
"checksum": {
|
|
1647
|
+
"algorithm": "sha256",
|
|
1648
|
+
"value": "c5a8077ee069e18fd6687c6b1c4f72fdbc95b7af77d954b6fb5e522cd783aa83"
|
|
1649
|
+
}
|
|
1650
|
+
},
|
|
1651
|
+
{
|
|
1652
|
+
"sourceName": "fortify",
|
|
1653
|
+
"rel": "raw-source",
|
|
1654
|
+
"mediaType": "application/zip",
|
|
1655
|
+
"encoding": "base64",
|
|
1656
|
+
"content": "UEsDBBQAAAAIAEVnPF20b/JoHgAAABwAAAAKAAAAYXVkaXQuZnZkbLOxr8jNUShLLSrOzM+zVTLUM1Cyt7NxC3Px0bcDAFBLAQIUAxQAAAAIAEVnPF20b/JoHgAAABwAAAAKAAAAAAAAAAAAAACAAQAAAABhdWRpdC5mdmRsUEsFBgAAAAABAAEAOAAAAEYAAAAAAA==",
|
|
1657
|
+
"checksum": {
|
|
1658
|
+
"algorithm": "sha256",
|
|
1659
|
+
"value": "c7e4cefceecb83511ae6174c7d22584061671dee6dc5f27243503b47532a66b1"
|
|
1660
|
+
}
|
|
1661
|
+
},
|
|
1662
|
+
{
|
|
1663
|
+
"sourceName": "nessus",
|
|
1664
|
+
"rel": "raw-source",
|
|
1665
|
+
"href": "https://scans.example.gov/exports/2026-09-27-prod-web.nessus",
|
|
1666
|
+
"mediaType": "application/xml",
|
|
1667
|
+
"checksum": {
|
|
1668
|
+
"algorithm": "sha256",
|
|
1669
|
+
"value": "a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2c3d4e5f6a1b2"
|
|
1670
|
+
}
|
|
1671
|
+
}
|
|
1672
|
+
]
|
|
1673
|
+
},
|
|
1674
|
+
"Extensions": {
|
|
1675
|
+
"type": "object",
|
|
1676
|
+
"additionalProperties": false,
|
|
1677
|
+
"properties": {
|
|
1678
|
+
"passthrough": {
|
|
1679
|
+
"type": "object",
|
|
1680
|
+
"additionalProperties": true,
|
|
1681
|
+
"description": "Catch-all for producer data that HDF does not model — the role heimdall2's `passthrough.auxiliary_data` played: fields a converter deliberately carried but had no home for.\n\nDeliberately permissive: unenumerated properties are accepted by design, with no shape imposed on them. HDF neither reads nor interprets what is here. It is the ONLY permissive surface in `extensions` — everything HDF does not define belongs here rather than beside it.\n\nThis is NOT where the pre-converted source artifact goes. v2 put it here only because nothing else had room; `rawSourceArtifacts` is its home now, and it gives the bytes a checksum, a media type and a reference contract that an untyped object cannot.\n\nFor data that belongs to one requirement rather than to the document, use that object's own fields — a document-level bag cannot say which requirement it describes.",
|
|
1682
|
+
"examples": [
|
|
1683
|
+
{
|
|
1684
|
+
"auxiliary_data": [
|
|
1685
|
+
{
|
|
1686
|
+
"name": "Scoutsuite",
|
|
1687
|
+
"data": {
|
|
1688
|
+
"last_run": {
|
|
1689
|
+
"ruleset_about": "This ruleset consists of numerous rules that are considered standard by NCC Group"
|
|
1690
|
+
}
|
|
1691
|
+
}
|
|
1692
|
+
}
|
|
1693
|
+
]
|
|
1694
|
+
},
|
|
1695
|
+
{
|
|
1696
|
+
"audit": {
|
|
1697
|
+
"runId": "r-123"
|
|
1698
|
+
}
|
|
1699
|
+
}
|
|
1700
|
+
],
|
|
1701
|
+
"$comment": "Examples, in order: 1) heimdall2's auxiliary_data shape, the data a v2 mapper carried with nowhere else to put it; 2) the legacy top-level `passthrough` an HDF document arrived with, relocated here verbatim by the SAF-supplement normalizer."
|
|
1702
|
+
},
|
|
1703
|
+
"rawSourceArtifacts": {
|
|
1704
|
+
"type": "array",
|
|
1705
|
+
"items": {
|
|
1706
|
+
"$ref": "#/$defs/Raw_Source_Artifact"
|
|
1707
|
+
},
|
|
1708
|
+
"description": "The input(s) this document was converted from, verbatim.\n\nAn array because a conversion can consume more than one artifact — the OSCAL profile path takes a profile and a catalog. Every other converter takes one input, and an array of one costs nothing.\n\nPopulating this is required of ingest converters by policy, enforced by the converter contract and test harness rather than by a schema `required`: a tool that emits HDF natively has no source artifact, and requiring the field would make valid native HDF invalid."
|
|
1709
|
+
}
|
|
1710
|
+
},
|
|
1711
|
+
"title": "Extensions",
|
|
1712
|
+
"description": "Carrier for data outside the HDF model: `passthrough` for producer data HDF does not model, `rawSourceArtifacts` for the pre-converted input(s).\n\nCLOSED: these two members are the whole of it. A key HDF does not define goes inside `passthrough` — that is what `passthrough` is for — so `extensions` never becomes a second, unnamed schema that consumers must reverse-engineer from the producers that happen to write it.\n\nClosed with `additionalProperties` rather than the house `unevaluatedProperties` because this definition composes nothing, and the shipped Go validator is a draft-07 engine that does not implement `unevaluatedProperties` — a closure only one of the two validators enforces is not a closure.\n\nDeclared on every HDF document type that carries a producer envelope (`generator` / `integrity`), and on `Evaluated_Baseline`, so one rule governs both sites.",
|
|
1713
|
+
"$comment": "Examples, in order: 1) the whole contract in one object — a converter's input embedded beside the producer data it could not map; 2) carriage alone, the shape a converter emits when it has nothing homeless to record.",
|
|
1714
|
+
"examples": [
|
|
1715
|
+
{
|
|
1716
|
+
"passthrough": {
|
|
1717
|
+
"auxiliary_data": [
|
|
1718
|
+
{
|
|
1719
|
+
"name": "Grype",
|
|
1720
|
+
"data": {
|
|
1721
|
+
"descriptor": {
|
|
1722
|
+
"name": "grype",
|
|
1723
|
+
"version": "0.74.0"
|
|
1724
|
+
}
|
|
1725
|
+
}
|
|
1726
|
+
}
|
|
1727
|
+
]
|
|
1728
|
+
},
|
|
1729
|
+
"rawSourceArtifacts": [
|
|
1730
|
+
{
|
|
1731
|
+
"sourceName": "grype",
|
|
1732
|
+
"rel": "raw-source",
|
|
1733
|
+
"mediaType": "application/json",
|
|
1734
|
+
"encoding": "utf-8",
|
|
1735
|
+
"content": "{\"matches\":[{\"vulnerability\":{\"id\":\"CVE-2021-36159\",\"severity\":\"Critical\"}}]}",
|
|
1736
|
+
"checksum": {
|
|
1737
|
+
"algorithm": "sha256",
|
|
1738
|
+
"value": "4b33be77f104d6ee323ff2c945d1c3f9a151606b2d263ea7932716844c75920c"
|
|
1739
|
+
}
|
|
1740
|
+
}
|
|
1741
|
+
]
|
|
1742
|
+
},
|
|
1743
|
+
{
|
|
1744
|
+
"rawSourceArtifacts": [
|
|
1745
|
+
{
|
|
1746
|
+
"sourceName": "fortify",
|
|
1747
|
+
"rel": "raw-source",
|
|
1748
|
+
"mediaType": "application/zip",
|
|
1749
|
+
"encoding": "base64",
|
|
1750
|
+
"content": "UEsDBBQAAAAIAEVnPF20b/JoHgAAABwAAAAKAAAAYXVkaXQuZnZkbLOxr8jNUShLLSrOzM+zVTLUM1Cyt7NxC3Px0bcDAFBLAQIUAxQAAAAIAEVnPF20b/JoHgAAABwAAAAKAAAAAAAAAAAAAACAAQAAAABhdWRpdC5mdmRsUEsFBgAAAAABAAEAOAAAAEYAAAAAAA==",
|
|
1751
|
+
"checksum": {
|
|
1752
|
+
"algorithm": "sha256",
|
|
1753
|
+
"value": "c7e4cefceecb83511ae6174c7d22584061671dee6dc5f27243503b47532a66b1"
|
|
1754
|
+
}
|
|
1755
|
+
}
|
|
1756
|
+
]
|
|
1757
|
+
}
|
|
1758
|
+
]
|
|
1759
|
+
},
|
|
1488
1760
|
"Status_Override": {
|
|
1489
1761
|
"type": "object",
|
|
1490
1762
|
"unevaluatedProperties": false,
|
|
@@ -1511,20 +1783,20 @@
|
|
|
1511
1783
|
"externalReferences": {
|
|
1512
1784
|
"type": "array",
|
|
1513
1785
|
"items": {
|
|
1514
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
1786
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/External_Reference"
|
|
1515
1787
|
},
|
|
1516
1788
|
"description": "Optional references to the external artifacts behind this override (e.g. the STIX bundle/object or CTI feed motivating an E:A riskAdjustment). Inert context distinct from `evidence`; see External_Reference. Symmetric with Standalone_Override.externalReferences for the inline (results-embedded) override carrier."
|
|
1517
1789
|
},
|
|
1518
1790
|
"type": {
|
|
1519
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/amendments/v3.
|
|
1791
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/amendments/v3.8.0#/$defs/Override_Type",
|
|
1520
1792
|
"description": "The type of override applied to this requirement."
|
|
1521
1793
|
},
|
|
1522
1794
|
"status": {
|
|
1523
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/result/v3.
|
|
1795
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/result/v3.8.0#/$defs/Result_Status",
|
|
1524
1796
|
"description": "The new status this override sets for the requirement. Optional when only impact is being overridden."
|
|
1525
1797
|
},
|
|
1526
1798
|
"impact": {
|
|
1527
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/amendments/v3.
|
|
1799
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/amendments/v3.8.0#/$defs/Impact_Override",
|
|
1528
1800
|
"description": "Override to the requirement's impact score. At least one of status or impact must be set."
|
|
1529
1801
|
},
|
|
1530
1802
|
"reason": {
|
|
@@ -1532,7 +1804,7 @@
|
|
|
1532
1804
|
"description": "Explanation for why this override was applied."
|
|
1533
1805
|
},
|
|
1534
1806
|
"appliedBy": {
|
|
1535
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
1807
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Identity",
|
|
1536
1808
|
"description": "Identity of who applied this override. For simple cases, use type 'simple' with just an identifier."
|
|
1537
1809
|
},
|
|
1538
1810
|
"appliedAt": {
|
|
@@ -1546,27 +1818,27 @@
|
|
|
1546
1818
|
"description": "Timestamp when this override expires and must be reviewed/renewed. REQUIRED - no permanent overrides allowed. ISO 8601 format."
|
|
1547
1819
|
},
|
|
1548
1820
|
"signature": {
|
|
1549
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
1821
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Signature",
|
|
1550
1822
|
"description": "Optional digital signature for enhanced trust and non-repudiation. Supports hardware security tokens (PKCS#11/PKCS#12), Yubikeys, GPG keys, passkeys, and other signing methods."
|
|
1551
1823
|
},
|
|
1552
1824
|
"evidence": {
|
|
1553
1825
|
"type": "array",
|
|
1554
1826
|
"items": {
|
|
1555
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
1827
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Evidence"
|
|
1556
1828
|
},
|
|
1557
1829
|
"description": "Supporting evidence for this override, such as screenshots demonstrating manual verification for attestations."
|
|
1558
1830
|
},
|
|
1559
1831
|
"previousChecksum": {
|
|
1560
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
1832
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Checksum",
|
|
1561
1833
|
"description": "SHA-256 checksum of the previous amendment in chronological order. Each amendment's checksum is recorded by the NEXT one, so editing an amendment in place is detectable — provided a later amendment is chained to it. It is NOT tamper-proof: the final amendment, the document envelope, deleted trailing amendments, and a chain that has been stripped or recomputed wholesale are all outside what it can detect. Use signature for non-repudiation. Omitted on the first amendment on a requirement."
|
|
1562
1834
|
},
|
|
1563
1835
|
"cvss": {
|
|
1564
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/cvss/v3.
|
|
1836
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/cvss/v3.8.0#/$defs/Cvss",
|
|
1565
1837
|
"$comment": "When present alongside impact.value on a riskAdjustment override, impact.value should be approximately cvss.computedScore / 10.0. Soft consistency rule — validators may warn but should not error. The cvss block makes Environmental/Threat enrichment auditable.",
|
|
1566
1838
|
"description": "Structured CVSS scoring data backing this override. Captures the rubric (which Environmental/Threat metrics the consumer modified, the recomputed score) used to justify a riskAdjustment. For other override types this is optional context."
|
|
1567
1839
|
},
|
|
1568
1840
|
"justification": {
|
|
1569
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/amendments/v3.
|
|
1841
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/amendments/v3.8.0#/$defs/Justification",
|
|
1570
1842
|
"description": "Structured controlled-vocabulary classification for why this override applies. Complements (does not replace) the free-text 'reason' field. Most useful on falsePositive and attestation overrides where the structured category enables filtering and lossless round-trip with VEX / OSCAL / FedRAMP DR. See the Justification primitive for the precedent vocabulary and rationale."
|
|
1571
1843
|
}
|
|
1572
1844
|
},
|
|
@@ -1702,7 +1974,7 @@
|
|
|
1702
1974
|
"description": "Detailed explanation of the plan, including what actions will be taken."
|
|
1703
1975
|
},
|
|
1704
1976
|
"appliedBy": {
|
|
1705
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
1977
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Identity",
|
|
1706
1978
|
"description": "Identity of who created this POA&M. For simple cases, use type 'simple' with just an identifier."
|
|
1707
1979
|
},
|
|
1708
1980
|
"appliedAt": {
|
|
@@ -1718,23 +1990,23 @@
|
|
|
1718
1990
|
"milestones": {
|
|
1719
1991
|
"type": "array",
|
|
1720
1992
|
"items": {
|
|
1721
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
1993
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Milestone"
|
|
1722
1994
|
},
|
|
1723
1995
|
"description": "Optional array of milestones tracking progress toward completion."
|
|
1724
1996
|
},
|
|
1725
1997
|
"signature": {
|
|
1726
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
1998
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Signature",
|
|
1727
1999
|
"description": "Optional digital signature for enhanced trust and non-repudiation."
|
|
1728
2000
|
},
|
|
1729
2001
|
"evidence": {
|
|
1730
2002
|
"type": "array",
|
|
1731
2003
|
"items": {
|
|
1732
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
2004
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Evidence"
|
|
1733
2005
|
},
|
|
1734
2006
|
"description": "Supporting evidence for this POA&M, such as documentation of compensating controls or mitigation implementation."
|
|
1735
2007
|
},
|
|
1736
2008
|
"previousChecksum": {
|
|
1737
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
2009
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Checksum",
|
|
1738
2010
|
"description": "SHA-256 checksum of the previous amendment in chronological order. Each amendment's checksum is recorded by the NEXT one, so editing an amendment in place is detectable — provided a later amendment is chained to it. It is NOT tamper-proof: the final amendment, the document envelope, deleted trailing amendments, and a chain that has been stripped or recomputed wholesale are all outside what it can detect. Use signature for non-repudiation. Omitted on the first amendment on a requirement."
|
|
1739
2011
|
}
|
|
1740
2012
|
},
|
|
@@ -1877,17 +2149,9 @@
|
|
|
1877
2149
|
"Integrity": {
|
|
1878
2150
|
"type": "object",
|
|
1879
2151
|
"unevaluatedProperties": false,
|
|
1880
|
-
"dependentRequired": {
|
|
1881
|
-
"algorithm": [
|
|
1882
|
-
"checksum"
|
|
1883
|
-
],
|
|
1884
|
-
"checksum": [
|
|
1885
|
-
"algorithm"
|
|
1886
|
-
]
|
|
1887
|
-
},
|
|
1888
2152
|
"properties": {
|
|
1889
2153
|
"algorithm": {
|
|
1890
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
2154
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Hash_Algorithm",
|
|
1891
2155
|
"description": "The hash algorithm used for the checksum."
|
|
1892
2156
|
},
|
|
1893
2157
|
"checksum": {
|
|
@@ -1916,13 +2180,39 @@
|
|
|
1916
2180
|
}
|
|
1917
2181
|
],
|
|
1918
2182
|
"description": "Cryptographic integrity information for verifying the HDF file has not been tampered with. If algorithm is provided, checksum must also be provided, and vice versa.",
|
|
1919
|
-
"title": "Integrity"
|
|
2183
|
+
"title": "Integrity",
|
|
2184
|
+
"allOf": [
|
|
2185
|
+
{
|
|
2186
|
+
"if": {
|
|
2187
|
+
"required": [
|
|
2188
|
+
"algorithm"
|
|
2189
|
+
]
|
|
2190
|
+
},
|
|
2191
|
+
"then": {
|
|
2192
|
+
"required": [
|
|
2193
|
+
"checksum"
|
|
2194
|
+
]
|
|
2195
|
+
}
|
|
2196
|
+
},
|
|
2197
|
+
{
|
|
2198
|
+
"if": {
|
|
2199
|
+
"required": [
|
|
2200
|
+
"checksum"
|
|
2201
|
+
]
|
|
2202
|
+
},
|
|
2203
|
+
"then": {
|
|
2204
|
+
"required": [
|
|
2205
|
+
"algorithm"
|
|
2206
|
+
]
|
|
2207
|
+
}
|
|
2208
|
+
}
|
|
2209
|
+
]
|
|
1920
2210
|
}
|
|
1921
2211
|
}
|
|
1922
2212
|
},
|
|
1923
|
-
"https://mitre.github.io/hdf-libs/schemas/primitives/amendments/v3.
|
|
2213
|
+
"https://mitre.github.io/hdf-libs/schemas/primitives/amendments/v3.8.0": {
|
|
1924
2214
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
1925
|
-
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/amendments/v3.
|
|
2215
|
+
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/amendments/v3.8.0",
|
|
1926
2216
|
"title": "HDF Amendment Primitives",
|
|
1927
2217
|
"description": "Types for waivers, attestations, and POA&Ms that modify requirement compliance status.",
|
|
1928
2218
|
"$defs": {
|
|
@@ -2033,7 +2323,7 @@
|
|
|
2033
2323
|
"externalReferences": {
|
|
2034
2324
|
"type": "array",
|
|
2035
2325
|
"items": {
|
|
2036
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
2326
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/External_Reference"
|
|
2037
2327
|
},
|
|
2038
2328
|
"description": "Optional references to the external artifacts behind this override (e.g. the STIX bundle/object, advisory, or CTI feed that motivated it). Inert context distinct from `evidence`; see External_Reference."
|
|
2039
2329
|
},
|
|
@@ -2051,7 +2341,7 @@
|
|
|
2051
2341
|
"description": "Name of the baseline containing the requirement. Required when the system has multiple baselines with potentially overlapping requirement IDs."
|
|
2052
2342
|
},
|
|
2053
2343
|
"status": {
|
|
2054
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/result/v3.
|
|
2344
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/result/v3.8.0#/$defs/Result_Status",
|
|
2055
2345
|
"description": "The new status this amendment sets. Optional when only impact is being overridden."
|
|
2056
2346
|
},
|
|
2057
2347
|
"impact": {
|
|
@@ -2063,7 +2353,7 @@
|
|
|
2063
2353
|
"description": "Justification for this amendment."
|
|
2064
2354
|
},
|
|
2065
2355
|
"appliedBy": {
|
|
2066
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
2356
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Identity",
|
|
2067
2357
|
"description": "Identity of who applied this amendment."
|
|
2068
2358
|
},
|
|
2069
2359
|
"appliedAt": {
|
|
@@ -2079,20 +2369,20 @@
|
|
|
2079
2369
|
"evidence": {
|
|
2080
2370
|
"type": "array",
|
|
2081
2371
|
"items": {
|
|
2082
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
2372
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Evidence"
|
|
2083
2373
|
},
|
|
2084
2374
|
"description": "Supporting evidence (screenshots, logs, URLs, documents)."
|
|
2085
2375
|
},
|
|
2086
2376
|
"signature": {
|
|
2087
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
2377
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Signature",
|
|
2088
2378
|
"description": "Digital signature for non-repudiation."
|
|
2089
2379
|
},
|
|
2090
2380
|
"previousChecksum": {
|
|
2091
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
2381
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Checksum",
|
|
2092
2382
|
"description": "SHA-256 checksum of the prior amendment in chronological order. Each amendment's checksum is recorded by the NEXT one, so editing an amendment in place is detectable — provided a later amendment is chained to it. It is NOT tamper-proof: the final amendment, the document envelope, deleted trailing amendments, and a chain that has been stripped or recomputed wholesale are all outside what it can detect. Use signature for non-repudiation. Omitted on the first amendment."
|
|
2093
2383
|
},
|
|
2094
2384
|
"cvss": {
|
|
2095
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/cvss/v3.
|
|
2385
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/cvss/v3.8.0#/$defs/Cvss",
|
|
2096
2386
|
"$comment": "When present alongside impact.value on a riskAdjustment override, impact.value should be approximately cvss.computedScore / 10.0. Soft consistency rule — validators may warn but should not error. The cvss block makes Environmental/Threat enrichment auditable.",
|
|
2097
2387
|
"description": "Structured CVSS scoring data backing this override. Captures the rubric (which Environmental/Threat metrics the consumer modified, the recomputed score) used to justify a riskAdjustment. For other override types this is optional context."
|
|
2098
2388
|
},
|
|
@@ -2103,7 +2393,7 @@
|
|
|
2103
2393
|
"milestones": {
|
|
2104
2394
|
"type": "array",
|
|
2105
2395
|
"items": {
|
|
2106
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.
|
|
2396
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/common/v3.8.0#/$defs/Milestone"
|
|
2107
2397
|
},
|
|
2108
2398
|
"description": "Remediation milestones (primarily for POA&M type amendments)."
|
|
2109
2399
|
},
|
|
@@ -2120,7 +2410,7 @@
|
|
|
2120
2410
|
"affectedPackages": {
|
|
2121
2411
|
"type": "array",
|
|
2122
2412
|
"items": {
|
|
2123
|
-
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/affected-package/v3.
|
|
2413
|
+
"$ref": "https://mitre.github.io/hdf-libs/schemas/primitives/affected-package/v3.8.0#/$defs/Affected_Package"
|
|
2124
2414
|
},
|
|
2125
2415
|
"description": "Software packages this amendment is scoped to, distinct from componentRef (which scopes to an HDF-internal Component by UUID).\n\nUse when the source amendment format references packages by purl/cpe/name+version — e.g., VEX `affects[]` / `products[]`, OSCAL POA&M `subjects[]`, FedRAMP component-aware amendments.\n\nSymmetric with Evaluated_Requirement.affectedPackages, which scopes findings to the same package vocabulary.\n\nWhen omitted, the amendment applies system-wide (or only to componentRef when that is set)."
|
|
2126
2416
|
}
|
|
@@ -2253,9 +2543,9 @@
|
|
|
2253
2543
|
}
|
|
2254
2544
|
}
|
|
2255
2545
|
},
|
|
2256
|
-
"https://mitre.github.io/hdf-libs/schemas/primitives/result/v3.
|
|
2546
|
+
"https://mitre.github.io/hdf-libs/schemas/primitives/result/v3.8.0": {
|
|
2257
2547
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2258
|
-
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/result/v3.
|
|
2548
|
+
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/result/v3.8.0",
|
|
2259
2549
|
"title": "HDF Result Primitives",
|
|
2260
2550
|
"description": "Types for representing assessment results and statuses.",
|
|
2261
2551
|
"$defs": {
|
|
@@ -2320,6 +2610,10 @@
|
|
|
2320
2610
|
"type": "string"
|
|
2321
2611
|
},
|
|
2322
2612
|
"description": "The stacktrace/backtrace of the exception if one occurred."
|
|
2613
|
+
},
|
|
2614
|
+
"rawSourceRecord": {
|
|
2615
|
+
"$ref": "#/$defs/Raw_Source_Record",
|
|
2616
|
+
"description": "The source tool's own record for this result, carrying every field the record had. Complete, not necessarily byte-exact: see Raw_Source_Record.content for the producer and consumer obligations, and extensions.rawSourceArtifacts[] when byte-exact carriage is required."
|
|
2323
2617
|
}
|
|
2324
2618
|
},
|
|
2325
2619
|
"examples": [
|
|
@@ -2350,6 +2644,64 @@
|
|
|
2350
2644
|
"description": "A test within a requirement and its results and findings such as how long it took to run.",
|
|
2351
2645
|
"title": "Requirement Result"
|
|
2352
2646
|
},
|
|
2647
|
+
"Raw_Source_Record": {
|
|
2648
|
+
"type": "object",
|
|
2649
|
+
"additionalProperties": false,
|
|
2650
|
+
"required": [
|
|
2651
|
+
"content",
|
|
2652
|
+
"encoding",
|
|
2653
|
+
"mediaType"
|
|
2654
|
+
],
|
|
2655
|
+
"properties": {
|
|
2656
|
+
"content": {
|
|
2657
|
+
"type": "string",
|
|
2658
|
+
"description": "The source tool's own record for this result, carrying every field the record had.\n\nCOMPLETE, NOT NECESSARILY BYTE-EXACT. A producer SHOULD write the record's bytes unchanged where it can. A producer that cannot — notably one implemented in two languages whose JSON serializers disagree on key order, HTML escaping and number rendering, and which therefore MUST canonicalize to stay byte-identical with its twin — MAY write a canonically serialized form instead. Such a form preserves every field and value but not the original key order, insignificant whitespace, or duplicate keys. A consumer MUST therefore compare records by parsing them, not by comparing bytes, and MUST NOT checksum this field and expect the result to match a checksum of the input.\n\nFor carriage that IS byte-exact, use `extensions.rawSourceArtifacts[]`, which forbids a parsed `document` precisely so the bytes and their checksum survive; `pointer` ties this record to its position within that artifact."
|
|
2659
|
+
},
|
|
2660
|
+
"encoding": {
|
|
2661
|
+
"type": "string",
|
|
2662
|
+
"enum": [
|
|
2663
|
+
"utf-8",
|
|
2664
|
+
"base64"
|
|
2665
|
+
],
|
|
2666
|
+
"description": "How to read `content`: 'utf-8' for text, 'base64' for bytes that are not valid UTF-8 text."
|
|
2667
|
+
},
|
|
2668
|
+
"mediaType": {
|
|
2669
|
+
"type": "string",
|
|
2670
|
+
"description": "The record's IANA media type — the type of this record, which for a fragment of a larger artifact may be narrower than the artifact's own. Example: 'application/json' for one match object out of a JSON report."
|
|
2671
|
+
},
|
|
2672
|
+
"pointer": {
|
|
2673
|
+
"type": "string",
|
|
2674
|
+
"description": "Where this record sits inside the artifact it came from, as a JSON Pointer (RFC 6901) for JSON sources or an XPath for XML ones. Example: '/matches/3'.\n\nOptional, and the link that makes carriage verifiable rather than merely present: with it a consumer can confirm the record really is the subtree of `extensions.rawSourceArtifacts[]` it claims to be. Omit it when the source's shape gives a record no addressable location."
|
|
2675
|
+
}
|
|
2676
|
+
},
|
|
2677
|
+
"description": "The source tool's own record for this result — the one entry in the converter's input that produced it, complete though not necessarily byte-for-byte (see `content`).\n\nSCOPED TO THE RESULT DELIBERATELY. For a vulnerability scanner the native record is one (vulnerability, package) pair, which is exactly one result: a CVE reported against two packages yields two entries whose records differ only in the package they matched. Held on the requirement instead, those two records would collide, and merging entries that share an id would have to discard one — so the result is not merely an available home but the correct one.\n\nDistinct from `extensions.rawSourceArtifacts[]`, which carries whole input artifacts: this carries the one record inside one of them, and `pointer` ties the two together. A consumer that wants the whole input reads the artifact; one that wants provenance for a single finding reads this.\n\nDistinct from `code`, which means the code that ran to evaluate the requirement — an InSpec control's source, or a check reference. A serialized finding is not code, and putting one there overloaded a field whose meaning came from InSpec.\n\nCLOSED, and deliberately not a passthrough bag: three required members and an optional pointer are the whole of it. Producer data that HDF does not model belongs in `extensions.passthrough`, which is document-scoped and permissive by design; this field is neither.\n\nClosed with `additionalProperties` rather than the house `unevaluatedProperties` because this definition composes nothing, and the shipped Go validator is a draft-07 engine that does not implement `unevaluatedProperties` — a closure only one of the two validators enforces is not a closure.",
|
|
2678
|
+
"$comment": "Examples, in order: 1) one grype match — the shape that moves out of `code` — located in the carried artifact by pointer; 2) an XCCDF rule-result, where the record is XML although the document embedding it is JSON, so mediaType is per record and not per document; 3) a record whose bytes are not text, carried as base64; 4) the minimum: a record whose source shape gives it no addressable location, so pointer is omitted.",
|
|
2679
|
+
"examples": [
|
|
2680
|
+
{
|
|
2681
|
+
"content": "{\"vulnerability\":{\"id\":\"CVE-2022-48174\",\"severity\":\"Critical\"},\"artifact\":{\"name\":\"ssl_client\",\"version\":\"1.31.1-r9\",\"type\":\"apk\"}}",
|
|
2682
|
+
"encoding": "utf-8",
|
|
2683
|
+
"mediaType": "application/json",
|
|
2684
|
+
"pointer": "/matches/3"
|
|
2685
|
+
},
|
|
2686
|
+
{
|
|
2687
|
+
"content": "<rule-result idref=\"xccdf_org.ssgproject.content_rule_sshd_disable_root_login\" severity=\"medium\">\n <result>fail</result>\n</rule-result>",
|
|
2688
|
+
"encoding": "utf-8",
|
|
2689
|
+
"mediaType": "application/xml",
|
|
2690
|
+
"pointer": "/Benchmark/TestResult/rule-result[4]"
|
|
2691
|
+
},
|
|
2692
|
+
{
|
|
2693
|
+
"content": "UEsDBBQAAAAIAEVnPF20b/JoHgAAABwAAAAKAAAAYXVkaXQuZnZkbA==",
|
|
2694
|
+
"encoding": "base64",
|
|
2695
|
+
"mediaType": "application/octet-stream"
|
|
2696
|
+
},
|
|
2697
|
+
{
|
|
2698
|
+
"content": "host-01,Ubuntu 22.04,CVE-2021-36159,,image,critical,apk-tools,apk-tools,2.12.5-r1",
|
|
2699
|
+
"encoding": "utf-8",
|
|
2700
|
+
"mediaType": "text/csv"
|
|
2701
|
+
}
|
|
2702
|
+
],
|
|
2703
|
+
"title": "Raw Source Record"
|
|
2704
|
+
},
|
|
2353
2705
|
"Requirement_Description": {
|
|
2354
2706
|
"type": "object",
|
|
2355
2707
|
"unevaluatedProperties": false,
|
|
@@ -2386,9 +2738,9 @@
|
|
|
2386
2738
|
}
|
|
2387
2739
|
}
|
|
2388
2740
|
},
|
|
2389
|
-
"https://mitre.github.io/hdf-libs/schemas/primitives/cvss/v3.
|
|
2741
|
+
"https://mitre.github.io/hdf-libs/schemas/primitives/cvss/v3.8.0": {
|
|
2390
2742
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2391
|
-
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/cvss/v3.
|
|
2743
|
+
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/cvss/v3.8.0",
|
|
2392
2744
|
"title": "HDF CVSS Primitives",
|
|
2393
2745
|
"description": "Types for representing CVSS (Common Vulnerability Scoring System) data attached to assessment findings. Supports CVSS v2.0, v3.0, v3.1, and v4.0 metric groups (Base, Threat, Environmental, Supplemental).",
|
|
2394
2746
|
"$defs": {
|
|
@@ -2585,9 +2937,9 @@
|
|
|
2585
2937
|
}
|
|
2586
2938
|
}
|
|
2587
2939
|
},
|
|
2588
|
-
"https://mitre.github.io/hdf-libs/schemas/primitives/affected-package/v3.
|
|
2940
|
+
"https://mitre.github.io/hdf-libs/schemas/primitives/affected-package/v3.8.0": {
|
|
2589
2941
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
2590
|
-
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/affected-package/v3.
|
|
2942
|
+
"$id": "https://mitre.github.io/hdf-libs/schemas/primitives/affected-package/v3.8.0",
|
|
2591
2943
|
"title": "HDF Affected Package Primitives",
|
|
2592
2944
|
"description": "Types for representing the software package(s) affected by a vulnerability finding.",
|
|
2593
2945
|
"$defs": {
|