@mitre/hdf-schema 3.2.0 → 3.3.0

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.
Files changed (37) hide show
  1. package/README.md +15 -16
  2. package/dist/go/hdf.go +398 -134
  3. package/dist/helpers.d.ts +1 -1
  4. package/dist/index.d.ts +27 -52
  5. package/dist/index.js +30 -48
  6. package/dist/schemas/hdf-amendments.schema.json +466 -45
  7. package/dist/schemas/hdf-baseline.schema.json +471 -50
  8. package/dist/schemas/hdf-comparison.schema.json +721 -103
  9. package/dist/schemas/hdf-evidence-package.schema.json +465 -44
  10. package/dist/schemas/hdf-plan.schema.json +472 -50
  11. package/dist/schemas/hdf-results.schema.json +678 -80
  12. package/dist/schemas/hdf-system.schema.json +497 -59
  13. package/dist/ts/hdf.d.ts +3562 -0
  14. package/dist/ts/hdf.js +564 -0
  15. package/dist/ts/hdf.ts +3623 -0
  16. package/package.json +18 -17
  17. package/dist/ts/hdf-amendments.d.ts +0 -474
  18. package/dist/ts/hdf-amendments.js +0 -88
  19. package/dist/ts/hdf-amendments.ts +0 -486
  20. package/dist/ts/hdf-baseline.d.ts +0 -549
  21. package/dist/ts/hdf-baseline.js +0 -110
  22. package/dist/ts/hdf-baseline.ts +0 -563
  23. package/dist/ts/hdf-comparison.d.ts +0 -1185
  24. package/dist/ts/hdf-comparison.js +0 -216
  25. package/dist/ts/hdf-comparison.ts +0 -1210
  26. package/dist/ts/hdf-evidence-package.d.ts +0 -348
  27. package/dist/ts/hdf-evidence-package.js +0 -39
  28. package/dist/ts/hdf-evidence-package.ts +0 -356
  29. package/dist/ts/hdf-plan.d.ts +0 -204
  30. package/dist/ts/hdf-plan.js +0 -23
  31. package/dist/ts/hdf-plan.ts +0 -205
  32. package/dist/ts/hdf-results.d.ts +0 -1588
  33. package/dist/ts/hdf-results.js +0 -246
  34. package/dist/ts/hdf-results.ts +0 -1616
  35. package/dist/ts/hdf-system.d.ts +0 -609
  36. package/dist/ts/hdf-system.js +0 -102
  37. package/dist/ts/hdf-system.ts +0 -617
@@ -1,348 +0,0 @@
1
- /**
2
- * Bundles references to all HDF documents for audit, authorization, and compliance review.
3
- * Each content entry references a document by type, URI, and checksum for integrity
4
- * verification.
5
- */
6
- export interface HdfEvidencePackage {
7
- /**
8
- * Summary of assessment completeness and compliance status.
9
- */
10
- completenessCheck?: CompletenessCheck;
11
- /**
12
- * References to HDF documents included in this evidence package.
13
- */
14
- contents: ContentReference[];
15
- /**
16
- * Description of the evidence package's purpose and scope.
17
- */
18
- description?: string;
19
- /**
20
- * Information about the tool that generated this document.
21
- */
22
- generator?: Generator;
23
- /**
24
- * Cryptographic integrity information for verifying this evidence package has not been
25
- * tampered with.
26
- */
27
- integrity?: Integrity;
28
- /**
29
- * Optional key-value labels for grouping and querying evidence packages.
30
- */
31
- labels?: {
32
- [key: string]: string;
33
- };
34
- /**
35
- * Human-readable name for this evidence package. Example: 'Enterprise Portal ATO Evidence -
36
- * Q1 2026'.
37
- */
38
- name: string;
39
- /**
40
- * Unique identifier for this evidence package. Optional in casual use, expected in
41
- * production ATO submissions. Auto-generated if omitted during creation.
42
- */
43
- packageId?: string;
44
- /**
45
- * URI to the hdf-plan document that drove this assessment. Used for completeness
46
- * verification — every baseline in the plan should have a corresponding results document in
47
- * this package.
48
- */
49
- planRef?: string;
50
- /**
51
- * When this evidence package was prepared. ISO 8601 format.
52
- */
53
- preparedAt?: Date;
54
- /**
55
- * Identity of who prepared this evidence package.
56
- */
57
- preparedBy?: Identity;
58
- /**
59
- * Digital signature covering the entire evidence package.
60
- */
61
- signature?: Signature;
62
- /**
63
- * URI to the hdf-system document this evidence package covers.
64
- */
65
- systemRef?: string;
66
- /**
67
- * Version of this evidence package.
68
- */
69
- version?: string;
70
- [property: string]: any;
71
- }
72
- /**
73
- * Summary of assessment completeness and compliance status.
74
- *
75
- * Informational summary of assessment completeness. Not authoritative — tools should
76
- * compute these from the referenced documents.
77
- */
78
- export interface CompletenessCheck {
79
- /**
80
- * Whether all baselines referenced by system components have assessment results.
81
- */
82
- allBaselinesAssessed?: boolean;
83
- /**
84
- * Whether all system components have at least one matching target in the results.
85
- */
86
- allComponentsCovered?: boolean;
87
- /**
88
- * Overall compliance percentage across all assessments.
89
- */
90
- compliancePercent?: number;
91
- /**
92
- * Number of waivers/amendments that have expired.
93
- */
94
- expiredWaivers?: number;
95
- /**
96
- * SBOM coverage across system components.
97
- */
98
- sbomCoverage?: SBOMCoverage;
99
- /**
100
- * Number of POA&M items that are still open (not completed).
101
- */
102
- unresolvedPoams?: number;
103
- [property: string]: any;
104
- }
105
- /**
106
- * SBOM coverage across system components.
107
- *
108
- * SBOM coverage statistics for the system.
109
- */
110
- export interface SBOMCoverage {
111
- /**
112
- * Number of system components that have an associated SBOM.
113
- */
114
- componentsWithSbom?: number;
115
- /**
116
- * Total number of components in the system.
117
- */
118
- totalComponents?: number;
119
- [property: string]: any;
120
- }
121
- /**
122
- * A reference to an HDF document or SBOM included in the evidence package.
123
- */
124
- export interface ContentReference {
125
- /**
126
- * Cryptographic checksum for verifying the referenced document's integrity.
127
- */
128
- checksum?: Checksum;
129
- /**
130
- * componentId of the component this content entry relates to. Use to link SBOMs, results,
131
- * or other documents to a specific system component.
132
- */
133
- componentRef?: string;
134
- /**
135
- * Optional description of this content entry.
136
- */
137
- description?: string;
138
- /**
139
- * The type of HDF document being referenced.
140
- */
141
- type: ContentType;
142
- /**
143
- * URI to the document. Can be a relative path or absolute URL.
144
- */
145
- uri: string;
146
- [property: string]: any;
147
- }
148
- /**
149
- * Cryptographic checksum for verifying the referenced document's integrity.
150
- *
151
- * Cryptographic checksum for baseline integrity verification.
152
- */
153
- export interface Checksum {
154
- /**
155
- * The hash algorithm used for the checksum.
156
- */
157
- algorithm: HashAlgorithm;
158
- /**
159
- * The checksum value.
160
- */
161
- value: string;
162
- [property: string]: any;
163
- }
164
- /**
165
- * The hash algorithm used for the checksum.
166
- *
167
- * Supported cryptographic hash algorithms for checksums and integrity verification.
168
- */
169
- export declare enum HashAlgorithm {
170
- Sha256 = "sha256",
171
- Sha384 = "sha384",
172
- Sha512 = "sha512"
173
- }
174
- /**
175
- * The type of HDF document being referenced.
176
- *
177
- * The type of document referenced in the evidence package.
178
- */
179
- export declare enum ContentType {
180
- HdfAmendments = "hdf-amendments",
181
- HdfBaseline = "hdf-baseline",
182
- HdfComparison = "hdf-comparison",
183
- HdfPlan = "hdf-plan",
184
- HdfResults = "hdf-results",
185
- HdfSystem = "hdf-system",
186
- Sbom = "sbom"
187
- }
188
- /**
189
- * Information about the tool that generated this document.
190
- *
191
- * Information about the tool that generated this HDF file.
192
- */
193
- export interface Generator {
194
- /**
195
- * The name of the software that produced this HDF file. Example: 'gosec-to-hdf'.
196
- */
197
- name: string;
198
- /**
199
- * The version of the tool. Example: '5.22.3'.
200
- */
201
- version: string;
202
- [property: string]: any;
203
- }
204
- /**
205
- * Cryptographic integrity information for verifying this evidence package has not been
206
- * tampered with.
207
- *
208
- * Cryptographic integrity information for verifying the HDF file has not been tampered
209
- * with. If algorithm is provided, checksum must also be provided, and vice versa.
210
- */
211
- export interface Integrity {
212
- /**
213
- * The hash algorithm used for the checksum.
214
- */
215
- algorithm?: HashAlgorithm;
216
- /**
217
- * The checksum value.
218
- */
219
- checksum?: string;
220
- /**
221
- * Optional cryptographic signature.
222
- */
223
- signature?: string;
224
- /**
225
- * Identifier of who signed this file.
226
- */
227
- signedBy?: string;
228
- [property: string]: any;
229
- }
230
- /**
231
- * Identity of who prepared this evidence package.
232
- *
233
- * Represents an identity that performed an action, such as capturing evidence or applying
234
- * an override.
235
- *
236
- * The identity that created this signature.
237
- */
238
- export interface Identity {
239
- /**
240
- * Optional description of the identity or identity system, particularly useful when type is
241
- * 'other'.
242
- */
243
- description?: string;
244
- /**
245
- * The identifier value. Example: 'user@example.com', 'jdoe', 'automated-scanner-01'.
246
- */
247
- identifier: string;
248
- /**
249
- * The type of identifier. Use 'email' for email addresses, 'username' for user accounts,
250
- * 'system' for automated systems, 'simple' for basic string identifiers without additional
251
- * classification, or 'other' for custom identity systems.
252
- */
253
- type: Type;
254
- [property: string]: any;
255
- }
256
- /**
257
- * The type of identifier. Use 'email' for email addresses, 'username' for user accounts,
258
- * 'system' for automated systems, 'simple' for basic string identifiers without additional
259
- * classification, or 'other' for custom identity systems.
260
- */
261
- export declare enum Type {
262
- Email = "email",
263
- Other = "other",
264
- Simple = "simple",
265
- System = "system",
266
- Username = "username"
267
- }
268
- /**
269
- * Digital signature covering the entire evidence package.
270
- *
271
- * A digital signature following W3C Data Integrity Proofs pattern. Supports hardware
272
- * security tokens (PKCS#11/PKCS#12), Yubikeys, GPG keys, passkeys, and other cryptographic
273
- * signing methods via JWK, PEM, or Base58 key formats.
274
- */
275
- export interface Signature {
276
- /**
277
- * Challenge value from the verifier, used in challenge-response authentication.
278
- */
279
- challenge?: string;
280
- /**
281
- * When the signature was created. ISO 8601 format.
282
- */
283
- created: Date;
284
- /**
285
- * The identity that created this signature.
286
- */
287
- creator: Identity;
288
- /**
289
- * Domain restriction for the signature, prevents cross-domain replay attacks.
290
- */
291
- domain?: string;
292
- /**
293
- * Random value to prevent replay attacks.
294
- */
295
- nonce?: string;
296
- /**
297
- * The purpose of this signature. Example: 'attestation', 'authentication',
298
- * 'assertionMethod'.
299
- */
300
- proofPurpose: string;
301
- /**
302
- * The base64-encoded or base58-encoded signature value.
303
- */
304
- signatureValue: string;
305
- /**
306
- * The signature suite type. Example: 'JsonWebSignature2020', 'RsaSignature2018',
307
- * 'Ed25519Signature2020'.
308
- */
309
- type: string;
310
- /**
311
- * The verification method containing the public key for signature verification.
312
- */
313
- verificationMethod: VerificationMethod;
314
- [property: string]: any;
315
- }
316
- /**
317
- * The verification method containing the public key for signature verification.
318
- *
319
- * Verification method containing the public key needed to verify a digital signature.
320
- * Supports multiple key formats including JWK (for RSA, EC), PEM, and Base58.
321
- */
322
- export interface VerificationMethod {
323
- /**
324
- * The entity that controls this verification method. Can be a DID, URI, or other identifier.
325
- */
326
- controller: string;
327
- /**
328
- * Public key in Base58 format, commonly used with Ed25519 keys.
329
- */
330
- publicKeyBase58?: string;
331
- /**
332
- * Public key in JSON Web Key format.
333
- */
334
- publicKeyJwk?: {
335
- [key: string]: any;
336
- };
337
- /**
338
- * Public key in PEM format. Example: '-----BEGIN PUBLIC KEY-----...-----END PUBLIC
339
- * KEY-----'.
340
- */
341
- publicKeyPem?: string;
342
- /**
343
- * The type of verification method. Example: 'JsonWebKey2020', 'RsaVerificationKey2018',
344
- * 'Ed25519VerificationKey2020'.
345
- */
346
- type: string;
347
- [property: string]: any;
348
- }
@@ -1,39 +0,0 @@
1
- /**
2
- * The hash algorithm used for the checksum.
3
- *
4
- * Supported cryptographic hash algorithms for checksums and integrity verification.
5
- */
6
- export var HashAlgorithm;
7
- (function (HashAlgorithm) {
8
- HashAlgorithm["Sha256"] = "sha256";
9
- HashAlgorithm["Sha384"] = "sha384";
10
- HashAlgorithm["Sha512"] = "sha512";
11
- })(HashAlgorithm || (HashAlgorithm = {}));
12
- /**
13
- * The type of HDF document being referenced.
14
- *
15
- * The type of document referenced in the evidence package.
16
- */
17
- export var ContentType;
18
- (function (ContentType) {
19
- ContentType["HdfAmendments"] = "hdf-amendments";
20
- ContentType["HdfBaseline"] = "hdf-baseline";
21
- ContentType["HdfComparison"] = "hdf-comparison";
22
- ContentType["HdfPlan"] = "hdf-plan";
23
- ContentType["HdfResults"] = "hdf-results";
24
- ContentType["HdfSystem"] = "hdf-system";
25
- ContentType["Sbom"] = "sbom";
26
- })(ContentType || (ContentType = {}));
27
- /**
28
- * The type of identifier. Use 'email' for email addresses, 'username' for user accounts,
29
- * 'system' for automated systems, 'simple' for basic string identifiers without additional
30
- * classification, or 'other' for custom identity systems.
31
- */
32
- export var Type;
33
- (function (Type) {
34
- Type["Email"] = "email";
35
- Type["Other"] = "other";
36
- Type["Simple"] = "simple";
37
- Type["System"] = "system";
38
- Type["Username"] = "username";
39
- })(Type || (Type = {}));