| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321 |
- {
- "$schema": "https://json-schema.org/draft/2020-12/schema",
- "$id": "prod2u-p4-normal-v3-strict-offline-gate-v1",
- "type": "object",
- "additionalProperties": false,
- "required": ["schema", "status", "verification_run_id", "commit", "source_state", "build_identity", "required_layers", "layers", "failures", "safety"],
- "properties": {
- "schema": {"const": "prod2u-p4-normal-v3-strict-offline-gate-v1"},
- "generated_at": {"type": "string", "minLength": 1},
- "status": {"enum": ["pass", "fail"]},
- "verification_run_id": {"type": "string", "pattern": "^[0-9a-f]{32}$"},
- "commit": {"type": "string", "pattern": "^[0-9a-f]{40}$|^$"},
- "source_state": {"type": "object"},
- "build_identity": {
- "type": ["object", "null"],
- "required": ["schema", "build_id", "build_epoch_utc", "generated_at_utc"],
- "properties": {
- "schema": {"const": "prod2u-p4-normal-v3-build-identity-v1"},
- "build_id": {"type": "string", "pattern": "^[0-9A-F]{8}$"},
- "build_epoch_utc": {"type": "integer", "minimum": 1, "maximum": 4294967295},
- "generated_at_utc": {"type": "string", "format": "date-time"}
- },
- "additionalProperties": false
- },
- "profile": {"const": "prod2u_p4_normal_v3"},
- "runtime_profile": {"const": "prod2u-p4-normal-actuator-trace-binary921-v3"},
- "required_layers": {
- "type": "array",
- "prefixItems": [
- {"const": "source_integrity"},
- {"const": "unit"},
- {"const": "hdl_sim"},
- {"const": "formal"}
- ],
- "minItems": 4,
- "maxItems": 4
- },
- "layers": {
- "type": "object",
- "required": ["source_integrity", "unit", "hdl_sim", "formal"],
- "properties": {
- "source_integrity": {
- "type": "object",
- "required": ["status", "returncode", "source_state"],
- "properties": {
- "status": {"type": "string"},
- "returncode": {"type": "integer"},
- "source_state": {"type": "object"}
- }
- },
- "unit": {
- "type": "object",
- "required": ["status", "returncode", "modules"],
- "properties": {
- "status": {"type": "string"},
- "returncode": {"type": "integer"},
- "modules": {"type": "array", "items": {"type": "string"}}
- }
- },
- "hdl_sim": {"type": "object"},
- "formal": {"type": "object"}
- },
- "additionalProperties": false
- },
- "failures": {"type": "array", "items": {"type": "string"}},
- "work_root": {"type": "string"},
- "child_receipt_dir": {"type": "string"},
- "safety": {
- "type": "object",
- "required": ["opens_serial", "programs_hardware", "installs_drivers"],
- "properties": {
- "opens_serial": {"const": false},
- "programs_hardware": {"const": false},
- "installs_drivers": {"const": false}
- },
- "additionalProperties": false
- },
- "authority_boundary": {"type": "string", "minLength": 40}
- },
- "$defs": {
- "targetManifestEvidence": {
- "type": "object",
- "required": ["schema", "version", "sha256", "layer", "status", "failures"],
- "properties": {
- "schema": {"const": "prod2u-p4-verification-target-manifest-v1"},
- "version": {"const": 1},
- "sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"},
- "layer": {"enum": ["unit", "icarus", "verilator", "cocotb", "formal", "all"]},
- "status": {"const": "pass"},
- "failures": {"type": "array", "maxItems": 0}
- },
- "additionalProperties": true
- },
- "sha256Path": {
- "type": "object",
- "required": ["path", "sha256"],
- "properties": {
- "path": {"type": "string", "minLength": 1},
- "sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}
- },
- "additionalProperties": false
- },
- "formalInputEvidence": {
- "type": "object",
- "required": ["sby", "sources", "task_engines", "sha256"],
- "properties": {
- "sby": {"$ref": "#/$defs/sha256Path"},
- "sources": {"type": "array", "minItems": 1, "items": {"$ref": "#/$defs/sha256Path"}},
- "task_engines": {
- "type": "object",
- "minProperties": 1,
- "additionalProperties": {
- "type": "array",
- "minItems": 1,
- "items": {"type": "string", "minLength": 1},
- "uniqueItems": true
- }
- },
- "sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"}
- },
- "additionalProperties": false
- },
- "formalToolEvidence": {
- "type": "object",
- "required": ["name", "path", "sha256", "version", "status", "failures"],
- "properties": {
- "name": {"type": "string", "minLength": 1},
- "path": {"type": "string", "minLength": 1},
- "sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"},
- "version": {"type": "string", "minLength": 1},
- "status": {"const": "pass"},
- "failures": {"type": "array", "maxItems": 0, "items": {"type": "string"}}
- },
- "additionalProperties": true
- }
- },
- "allOf": [
- {
- "if": {"properties": {"status": {"const": "pass"}}, "required": ["status"]},
- "then": {
- "required": ["generated_at", "profile", "runtime_profile", "work_root", "child_receipt_dir", "authority_boundary"],
- "properties": {
- "build_identity": {"type": "object"},
- "failures": {"maxItems": 0},
- "layers": {
- "properties": {
- "source_integrity": {
- "properties": {
- "status": {"const": "pass"},
- "returncode": {"const": 0},
- "source_state": {
- "required": ["clean"],
- "properties": {"clean": {"const": true}}
- }
- }
- },
- "unit": {
- "required": ["target_manifest"],
- "properties": {
- "status": {"const": "pass"},
- "returncode": {"const": 0},
- "modules": {"minItems": 1},
- "target_manifest": {"$ref": "#/$defs/targetManifestEvidence"}
- }
- },
- "hdl_sim": {
- "required": ["schema", "status", "verification_layer", "profile", "backend", "tests", "backend_results", "target_manifest", "safety"],
- "properties": {
- "schema": {"const": "prod2u-p4-normal-v3-hdl-sim-receipt-v1"},
- "status": {"const": "pass"},
- "verification_layer": {"const": "hdl_sim"},
- "profile": {"const": "prod2u_p4_normal_v3"},
- "backend": {"const": "all"},
- "target_manifest": {"$ref": "#/$defs/targetManifestEvidence"},
- "tests": {
- "type": "array",
- "minItems": 1,
- "items": {
- "type": "object",
- "required": ["name", "status"],
- "properties": {"status": {"const": "pass"}}
- }
- },
- "backend_results": {
- "type": "object",
- "required": ["icarus", "verilator", "cocotb"],
- "properties": {
- "icarus": {
- "required": ["status", "target_manifest"],
- "properties": {
- "status": {"const": "pass"},
- "target_manifest": {"$ref": "#/$defs/targetManifestEvidence"}
- }
- },
- "verilator": {
- "required": ["status", "target_manifest"],
- "properties": {
- "status": {"const": "pass"},
- "target_manifest": {"$ref": "#/$defs/targetManifestEvidence"}
- }
- },
- "cocotb": {
- "required": ["status", "target_manifest"],
- "properties": {
- "status": {"const": "pass"},
- "target_manifest": {"$ref": "#/$defs/targetManifestEvidence"}
- }
- }
- },
- "additionalProperties": false
- },
- "safety": {"const": {"opens_serial": false, "programs_hardware": false, "installs_drivers": false}}
- }
- },
- "formal": {
- "required": ["schema", "status", "verification_layer", "profile", "targets", "toolchain", "target_manifest", "safety"],
- "properties": {
- "schema": {"const": "prod2u-p4-normal-v3-formal-receipt-v1"},
- "status": {"const": "pass"},
- "verification_layer": {"const": "formal"},
- "profile": {"const": "prod2u_p4_normal_v3"},
- "toolchain": {
- "type": "object",
- "required": ["status", "sby", "yosys", "solvers", "failures"],
- "properties": {
- "status": {"const": "pass"},
- "sby": {"$ref": "#/$defs/formalToolEvidence"},
- "yosys": {"$ref": "#/$defs/formalToolEvidence"},
- "solvers": {"type": "array", "minItems": 1, "items": {"$ref": "#/$defs/formalToolEvidence"}},
- "failures": {"type": "array", "maxItems": 0, "items": {"type": "string"}}
- }
- },
- "target_manifest": {"$ref": "#/$defs/targetManifestEvidence"},
- "targets": {
- "type": "array",
- "minItems": 1,
- "items": {
- "type": "object",
- "required": [
- "name", "status", "tasks", "trace_files", "assertion_count",
- "cover_count", "cover_required", "cover_hit_count", "cover_hit_ids",
- "input_evidence", "task_results", "evidence_failures"
- ],
- "properties": {
- "status": {"const": "pass"},
- "tasks": {"type": "array", "items": {"type": "string", "minLength": 1}, "uniqueItems": true},
- "trace_files": {"type": "array", "items": {"type": "string", "minLength": 1}, "uniqueItems": true},
- "assertion_count": {"type": "integer", "minimum": 1},
- "cover_count": {"type": "integer", "minimum": 0},
- "cover_required": {"type": "boolean"},
- "cover_hit_count": {"type": "integer", "minimum": 0},
- "cover_hit_ids": {"type": "array", "items": {"type": "string", "minLength": 1}, "uniqueItems": true},
- "input_evidence": {"$ref": "#/$defs/formalInputEvidence"},
- "task_results": {
- "type": "array",
- "minItems": 1,
- "items": {
- "type": "object",
- "required": [
- "name", "mode", "status", "status_raw", "status_file", "workdir",
- "trace_files", "cover_hit_ids", "configured_engines", "observed_engines",
- "solvers", "compiled_design_json", "compiled_design_sha256",
- "compiled_assertion_count", "compiled_assertion_ids",
- "compiled_cover_count", "compiled_cover_ids", "evidence_failures"
- ],
- "properties": {
- "name": {"type": "string", "minLength": 1},
- "mode": {"type": "string"},
- "status": {"const": "PASS"},
- "status_raw": {"type": "string"},
- "status_file": {"type": "string", "minLength": 1},
- "workdir": {"type": "string", "minLength": 1},
- "trace_files": {"type": "array", "items": {"type": "string", "minLength": 1}, "uniqueItems": true},
- "cover_hit_ids": {"type": "array", "items": {"type": "string", "minLength": 1}, "uniqueItems": true},
- "configured_engines": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}, "uniqueItems": true},
- "observed_engines": {"type": "array", "minItems": 1, "items": {"type": "string", "minLength": 1}, "uniqueItems": true},
- "solvers": {"type": "array", "items": {"type": "string", "minLength": 1}, "uniqueItems": true},
- "compiled_design_json": {"type": "string", "minLength": 1},
- "compiled_design_sha256": {"type": "string", "pattern": "^[0-9a-f]{64}$"},
- "compiled_assertion_count": {"type": "integer", "minimum": 0},
- "compiled_assertion_ids": {"type": "array", "items": {"type": "string", "minLength": 1}, "uniqueItems": true},
- "compiled_cover_count": {"type": "integer", "minimum": 0},
- "compiled_cover_ids": {"type": "array", "items": {"type": "string", "minLength": 1}, "uniqueItems": true},
- "evidence_failures": {"type": "array", "maxItems": 0, "items": {"type": "string"}}
- },
- "allOf": [
- {
- "if": {"properties": {"mode": {"enum": ["prove", "bmc"]}}, "required": ["mode"]},
- "then": {
- "properties": {
- "compiled_assertion_count": {"minimum": 1},
- "compiled_assertion_ids": {"minItems": 1}
- }
- }
- },
- {
- "if": {"properties": {"mode": {"const": "cover"}}, "required": ["mode"]},
- "then": {
- "properties": {
- "compiled_cover_count": {"minimum": 1},
- "compiled_cover_ids": {"minItems": 1}
- }
- }
- }
- ]
- }
- },
- "evidence_failures": {"type": "array", "maxItems": 0, "items": {"type": "string"}}
- }
- }
- },
- "safety": {"const": {"opens_serial": false, "programs_hardware": false, "installs_drivers": false}}
- }
- }
- }
- }
- }
- }
- }
- ]
- }
|