tamperward 2.18.0 → 2.19.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.
@@ -0,0 +1,606 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://raw.githubusercontent.com/hexrift/tamperward/main/schemas/verify-v1.schema.json",
4
+ "title": "TamperWard verify JSON output v1",
5
+ "type": "object",
6
+ "required": [
7
+ "schema_version",
8
+ "verdict"
9
+ ],
10
+ "properties": {
11
+ "schema_version": {
12
+ "const": 1
13
+ },
14
+ "verdict": {
15
+ "enum": [
16
+ "VERIFIED",
17
+ "MASKED_FAILURE",
18
+ "SUITE_RED",
19
+ "BUDGET_EXCEEDED",
20
+ "CANNOT_VERIFY"
21
+ ]
22
+ },
23
+ "reason": {
24
+ "enum": [
25
+ "INVALID_ARGUMENTS",
26
+ "POLICY_ERROR",
27
+ "BASE_NOT_ANCESTOR",
28
+ "NO_SUITE_COMMAND",
29
+ "VERIFIER_BACKEND_UNAVAILABLE",
30
+ "LOCAL_VERIFIER_UNSUPPORTED_PLATFORM",
31
+ "DEPENDENCY_ENVIRONMENT_UNATTESTABLE",
32
+ "BASE_UNRESOLVABLE",
33
+ "DEPENDENCY_DRIFT",
34
+ "MATERIALIZATION_FAILED",
35
+ "VERIFIER_BACKEND_RUNTIME_FAILURE",
36
+ "VERIFIER_RESOURCE_EXHAUSTED",
37
+ "WORKTREE_CHANGED",
38
+ "PRISTINE_INTEGRITY_CHANGED"
39
+ ],
40
+ "description": "Machine reason for CANNOT_VERIFY. `stage` names the suite execution in flight, where one was."
41
+ },
42
+ "detail": {
43
+ "type": "string"
44
+ },
45
+ "base": {
46
+ "type": "string"
47
+ },
48
+ "command": {
49
+ "type": "string"
50
+ },
51
+ "budget_secs": {
52
+ "type": "number",
53
+ "exclusiveMinimum": 0
54
+ },
55
+ "stage": {
56
+ "enum": [
57
+ "visible",
58
+ "pristine"
59
+ ]
60
+ },
61
+ "resource": {
62
+ "type": "string"
63
+ },
64
+ "diagnostics": {
65
+ "$ref": "#/$defs/diagnostics"
66
+ },
67
+ "visible": {
68
+ "$ref": "#/$defs/stage"
69
+ },
70
+ "pristine": {
71
+ "$ref": "#/$defs/stage"
72
+ },
73
+ "protected_restored": {
74
+ "type": "integer",
75
+ "minimum": 0
76
+ },
77
+ "added_protected_removed": {
78
+ "type": "integer",
79
+ "minimum": 0
80
+ },
81
+ "verifier_backend": {
82
+ "$ref": "#/$defs/backend"
83
+ },
84
+ "dependency_environment": {
85
+ "$ref": "#/$defs/dependency_environment"
86
+ },
87
+ "oracle_assurance": {
88
+ "$ref": "#/$defs/oracle_assurance"
89
+ },
90
+ "oob_signoff": {
91
+ "type": "string"
92
+ },
93
+ "visible_dir": {
94
+ "type": "string"
95
+ },
96
+ "pristine_dir": {
97
+ "type": "string"
98
+ },
99
+ "platform": {
100
+ "type": "string"
101
+ }
102
+ },
103
+ "allOf": [
104
+ {
105
+ "if": {
106
+ "properties": {
107
+ "verdict": {
108
+ "const": "CANNOT_VERIFY"
109
+ }
110
+ },
111
+ "required": [
112
+ "verdict"
113
+ ],
114
+ "type": "object"
115
+ },
116
+ "then": {
117
+ "required": [
118
+ "reason"
119
+ ],
120
+ "properties": {
121
+ "reason": {}
122
+ },
123
+ "type": "object"
124
+ }
125
+ },
126
+ {
127
+ "if": {
128
+ "properties": {
129
+ "verdict": {
130
+ "enum": [
131
+ "VERIFIED",
132
+ "MASKED_FAILURE",
133
+ "SUITE_RED",
134
+ "BUDGET_EXCEEDED"
135
+ ]
136
+ }
137
+ },
138
+ "required": [
139
+ "verdict"
140
+ ],
141
+ "type": "object"
142
+ },
143
+ "then": {
144
+ "required": [
145
+ "base",
146
+ "command",
147
+ "budget_secs",
148
+ "visible",
149
+ "pristine",
150
+ "protected_restored",
151
+ "added_protected_removed",
152
+ "verifier_backend",
153
+ "dependency_environment",
154
+ "oracle_assurance"
155
+ ],
156
+ "properties": {
157
+ "base": {},
158
+ "command": {},
159
+ "budget_secs": {},
160
+ "visible": {},
161
+ "pristine": {},
162
+ "protected_restored": {},
163
+ "added_protected_removed": {},
164
+ "verifier_backend": {},
165
+ "dependency_environment": {},
166
+ "oracle_assurance": {}
167
+ },
168
+ "type": "object"
169
+ }
170
+ },
171
+ {
172
+ "if": {
173
+ "properties": {
174
+ "verdict": {
175
+ "const": "VERIFIED"
176
+ }
177
+ },
178
+ "required": [
179
+ "verdict"
180
+ ],
181
+ "type": "object"
182
+ },
183
+ "then": {
184
+ "properties": {
185
+ "visible": {
186
+ "allOf": [
187
+ {
188
+ "$ref": "#/$defs/stage"
189
+ },
190
+ {
191
+ "properties": {
192
+ "exit": {
193
+ "const": 0
194
+ }
195
+ },
196
+ "required": [
197
+ "exit"
198
+ ],
199
+ "type": "object"
200
+ }
201
+ ]
202
+ },
203
+ "pristine": {
204
+ "allOf": [
205
+ {
206
+ "$ref": "#/$defs/stage"
207
+ },
208
+ {
209
+ "properties": {
210
+ "exit": {
211
+ "const": 0
212
+ }
213
+ },
214
+ "required": [
215
+ "exit"
216
+ ],
217
+ "type": "object"
218
+ }
219
+ ]
220
+ }
221
+ },
222
+ "type": "object"
223
+ }
224
+ },
225
+ {
226
+ "if": {
227
+ "properties": {
228
+ "verdict": {
229
+ "const": "MASKED_FAILURE"
230
+ }
231
+ },
232
+ "required": [
233
+ "verdict"
234
+ ],
235
+ "type": "object"
236
+ },
237
+ "then": {
238
+ "properties": {
239
+ "visible": {
240
+ "allOf": [
241
+ {
242
+ "$ref": "#/$defs/stage"
243
+ },
244
+ {
245
+ "properties": {
246
+ "exit": {
247
+ "const": 0
248
+ }
249
+ },
250
+ "required": [
251
+ "exit"
252
+ ],
253
+ "type": "object"
254
+ }
255
+ ]
256
+ },
257
+ "pristine": {
258
+ "allOf": [
259
+ {
260
+ "$ref": "#/$defs/stage"
261
+ },
262
+ {
263
+ "properties": {
264
+ "exit": {
265
+ "type": "integer",
266
+ "not": {
267
+ "const": 0
268
+ }
269
+ }
270
+ },
271
+ "required": [
272
+ "exit"
273
+ ],
274
+ "type": "object"
275
+ }
276
+ ]
277
+ }
278
+ },
279
+ "type": "object"
280
+ }
281
+ },
282
+ {
283
+ "if": {
284
+ "properties": {
285
+ "verdict": {
286
+ "const": "SUITE_RED"
287
+ }
288
+ },
289
+ "required": [
290
+ "verdict"
291
+ ],
292
+ "type": "object"
293
+ },
294
+ "then": {
295
+ "properties": {
296
+ "visible": {
297
+ "allOf": [
298
+ {
299
+ "$ref": "#/$defs/stage"
300
+ },
301
+ {
302
+ "properties": {
303
+ "exit": {
304
+ "type": "integer",
305
+ "not": {
306
+ "const": 0
307
+ }
308
+ }
309
+ },
310
+ "required": [
311
+ "exit"
312
+ ],
313
+ "type": "object"
314
+ }
315
+ ]
316
+ }
317
+ },
318
+ "type": "object"
319
+ }
320
+ },
321
+ {
322
+ "if": {
323
+ "properties": {
324
+ "verdict": {
325
+ "const": "BUDGET_EXCEEDED"
326
+ }
327
+ },
328
+ "required": [
329
+ "verdict"
330
+ ],
331
+ "type": "object"
332
+ },
333
+ "then": {
334
+ "anyOf": [
335
+ {
336
+ "properties": {
337
+ "visible": {
338
+ "properties": {
339
+ "exit": {
340
+ "const": null
341
+ }
342
+ },
343
+ "required": [
344
+ "exit"
345
+ ],
346
+ "type": "object"
347
+ }
348
+ },
349
+ "required": [
350
+ "visible"
351
+ ],
352
+ "type": "object"
353
+ },
354
+ {
355
+ "properties": {
356
+ "pristine": {
357
+ "properties": {
358
+ "exit": {
359
+ "const": null
360
+ }
361
+ },
362
+ "required": [
363
+ "exit"
364
+ ],
365
+ "type": "object"
366
+ }
367
+ },
368
+ "required": [
369
+ "pristine"
370
+ ],
371
+ "type": "object"
372
+ }
373
+ ]
374
+ }
375
+ }
376
+ ],
377
+ "$defs": {
378
+ "stream": {
379
+ "type": "object",
380
+ "required": [
381
+ "captured_bytes",
382
+ "retained_bytes",
383
+ "truncated"
384
+ ],
385
+ "properties": {
386
+ "captured_bytes": {
387
+ "type": "integer",
388
+ "minimum": 0
389
+ },
390
+ "retained_bytes": {
391
+ "type": "integer",
392
+ "minimum": 0
393
+ },
394
+ "truncated": {
395
+ "type": "boolean"
396
+ },
397
+ "tail": {
398
+ "type": "string"
399
+ }
400
+ },
401
+ "additionalProperties": true
402
+ },
403
+ "diagnostics": {
404
+ "type": "object",
405
+ "required": [
406
+ "stdout",
407
+ "stderr"
408
+ ],
409
+ "properties": {
410
+ "stdout": {
411
+ "$ref": "#/$defs/stream"
412
+ },
413
+ "stderr": {
414
+ "$ref": "#/$defs/stream"
415
+ }
416
+ },
417
+ "additionalProperties": true
418
+ },
419
+ "stage": {
420
+ "type": "object",
421
+ "required": [
422
+ "exit",
423
+ "secs"
424
+ ],
425
+ "properties": {
426
+ "exit": {
427
+ "type": [
428
+ "integer",
429
+ "null"
430
+ ]
431
+ },
432
+ "secs": {
433
+ "type": "number",
434
+ "minimum": 0
435
+ },
436
+ "reason": {
437
+ "type": "string"
438
+ },
439
+ "diagnostics": {
440
+ "$ref": "#/$defs/diagnostics"
441
+ }
442
+ },
443
+ "additionalProperties": true
444
+ },
445
+ "backend": {
446
+ "type": "object",
447
+ "required": [
448
+ "kind",
449
+ "trust",
450
+ "available"
451
+ ],
452
+ "properties": {
453
+ "kind": {
454
+ "enum": [
455
+ "local",
456
+ "container"
457
+ ]
458
+ },
459
+ "trust": {
460
+ "enum": [
461
+ "checkpointed-local",
462
+ "isolated-container"
463
+ ]
464
+ },
465
+ "available": {
466
+ "type": "boolean"
467
+ },
468
+ "image": {
469
+ "type": "string"
470
+ },
471
+ "engine": {
472
+ "const": "docker"
473
+ },
474
+ "reason": {
475
+ "type": "string"
476
+ },
477
+ "resources": {
478
+ "type": "object",
479
+ "required": [
480
+ "memory_bytes",
481
+ "memory_swap_bytes",
482
+ "cpus",
483
+ "pids"
484
+ ],
485
+ "properties": {
486
+ "memory_bytes": {
487
+ "type": "integer",
488
+ "minimum": 1
489
+ },
490
+ "memory_swap_bytes": {
491
+ "type": "integer",
492
+ "minimum": 1
493
+ },
494
+ "cpus": {
495
+ "type": "number",
496
+ "exclusiveMinimum": 0
497
+ },
498
+ "pids": {
499
+ "type": "integer",
500
+ "minimum": 1
501
+ }
502
+ },
503
+ "additionalProperties": true
504
+ }
505
+ },
506
+ "additionalProperties": true
507
+ },
508
+ "dependency_environment": {
509
+ "type": "object",
510
+ "required": [
511
+ "status",
512
+ "roots"
513
+ ],
514
+ "properties": {
515
+ "status": {
516
+ "enum": [
517
+ "none",
518
+ "attested",
519
+ "unattestable",
520
+ "verifier-owned"
521
+ ]
522
+ },
523
+ "roots": {
524
+ "type": "array",
525
+ "items": {
526
+ "type": "object",
527
+ "required": [
528
+ "kind",
529
+ "path"
530
+ ],
531
+ "properties": {
532
+ "kind": {
533
+ "enum": [
534
+ "node_modules",
535
+ "python-venv"
536
+ ]
537
+ },
538
+ "path": {
539
+ "type": "string"
540
+ }
541
+ },
542
+ "additionalProperties": true
543
+ }
544
+ },
545
+ "fingerprint": {
546
+ "type": "string"
547
+ },
548
+ "reason": {
549
+ "type": "string"
550
+ },
551
+ "image": {
552
+ "type": "string"
553
+ },
554
+ "diagnostics": {
555
+ "type": "object",
556
+ "required": [
557
+ "full_snapshots",
558
+ "reused_snapshots",
559
+ "total_ms"
560
+ ],
561
+ "properties": {
562
+ "full_snapshots": {
563
+ "type": "integer",
564
+ "minimum": 0
565
+ },
566
+ "reused_snapshots": {
567
+ "type": "integer",
568
+ "minimum": 0
569
+ },
570
+ "total_ms": {
571
+ "type": "number",
572
+ "minimum": 0
573
+ }
574
+ },
575
+ "additionalProperties": true
576
+ }
577
+ },
578
+ "additionalProperties": true
579
+ },
580
+ "oracle_assurance": {
581
+ "type": "object",
582
+ "required": [
583
+ "level",
584
+ "semantic_isolation",
585
+ "candidate_code_executes_in_oracle_process",
586
+ "limitation"
587
+ ],
588
+ "properties": {
589
+ "level": {
590
+ "const": "suite-exit-only"
591
+ },
592
+ "semantic_isolation": {
593
+ "const": false
594
+ },
595
+ "candidate_code_executes_in_oracle_process": {
596
+ "const": true
597
+ },
598
+ "limitation": {
599
+ "type": "string"
600
+ }
601
+ },
602
+ "additionalProperties": true
603
+ }
604
+ },
605
+ "additionalProperties": true
606
+ }