settld 0.1.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.
- package/Dockerfile +45 -0
- package/README.md +150 -0
- package/SETTLD_VERSION +1 -0
- package/bin/settld.js +212 -0
- package/conformance/README.md +14 -0
- package/conformance/kernel-v0/README.md +60 -0
- package/conformance/kernel-v0/cases.json +19 -0
- package/conformance/kernel-v0/run.mjs +830 -0
- package/conformance/v1/README.md +77 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/evidence/evidence_index.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/settld.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/payload/invoice_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/settld.json +1 -0
- package/conformance/v1/bundles/closepack/nonstrict-pass-missing-sla-acceptance/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/acceptance/acceptance_criteria.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/acceptance/acceptance_evaluation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/evidence/evidence_index.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/settld.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/payload/invoice_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/settld.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/sla/sla_definition.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/sla/sla_evaluation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-embedded-invoice-fails/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/acceptance/acceptance_criteria.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/acceptance/acceptance_evaluation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/evidence/evidence_index.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/settld.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/payload/invoice_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/settld.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/sla/sla_definition.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/sla/sla_evaluation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-fail-evidence-index-mismatch/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/acceptance/acceptance_criteria.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/acceptance/acceptance_evaluation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/evidence/evidence_index.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/settld.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/payload/invoice_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/settld.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/sla/sla_definition.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/sla/sla_evaluation.json +1 -0
- package/conformance/v1/bundles/closepack/strict-pass/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/finance/GLBatch.v1.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/finance/JournalCsv.v1.csv +2 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/finance/JournalCsv.v1.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/finance/reconcile.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/governance/policy.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/governance/revocations.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/manifest.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/events/events.jsonl +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/governance/policy.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/governance/revocations.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/manifest.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/verify/report.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/month/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/settld.json +1 -0
- package/conformance/v1/bundles/financepack/pass-with-tool-version-unknown-warning/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/finance/GLBatch.v1.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/finance/JournalCsv.v1.csv +2 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/finance/JournalCsv.v1.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/finance/reconcile.json +2 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/governance/policy.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/governance/revocations.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/manifest.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/events/events.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/governance/policy.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/governance/revocations.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/manifest.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/verify/report.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/month/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/settld.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-manifest-tamper/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/finance/GLBatch.v1.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/finance/JournalCsv.v1.csv +2 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/finance/JournalCsv.v1.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/finance/reconcile.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/governance/policy.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/governance/revocations.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/manifest.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/events/events.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/governance/policy.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/governance/revocations.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/manifest.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/verify/report.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/month/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/financepack/strict-fail-missing-verification-report/settld.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/finance/GLBatch.v1.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/finance/JournalCsv.v1.csv +2 -0
- package/conformance/v1/bundles/financepack/strict-pass/finance/JournalCsv.v1.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/finance/reconcile.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/governance/policy.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/governance/revocations.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/manifest.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/events/events.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/governance/policy.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/governance/revocations.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/manifest.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/verify/report.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/month/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/settld.json +1 -0
- package/conformance/v1/bundles/financepack/strict-pass/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-missing-verification-report/settld.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/settld.json +1 -0
- package/conformance/v1/bundles/invoicebundle/nonstrict-pass-unsigned-pricing-matrix-warning/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/settld.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-evidence-sha-mismatch/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/settld.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invalid-pricing-matrix-signature/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/settld.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-invoice-total-mismatch/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/settld.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-pricing-matrix-signature/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-missing-verification-report/settld.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/settld.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-fail-pricing-code-unknown/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/invoice/invoice_claim.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/metering/metering_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/governance/policy.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/governance/revocations.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/job/snapshot.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/manifest.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/verify/report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/payload/job_proof_bundle/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/pricing/pricing_matrix.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/pricing/pricing_matrix_signatures.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/settld.json +1 -0
- package/conformance/v1/bundles/invoicebundle/strict-pass/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/events/events.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/governance/policy.json +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/governance/revocations.json +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/job/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/manifest.json +1 -0
- package/conformance/v1/bundles/jobproof/nonstrict-pass-missing-verification-report/verify/report.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/events/events.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/governance/policy.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/governance/revocations.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/job/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/manifest.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/verify/report.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-manifest-tamper/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/events/events.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/governance/policy.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/governance/revocations.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/job/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/manifest.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/verify/report.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-fail-unauthorized-signer/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/events/events.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/governance/policy.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/governance/revocations.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/jobproof/strict-pass/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/jobproof/strict-pass/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/job/snapshot.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/manifest.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/verify/report.json +1 -0
- package/conformance/v1/bundles/jobproof/strict-pass/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/events/events.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/governance/policy.json +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/governance/revocations.json +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/manifest.json +1 -0
- package/conformance/v1/bundles/monthproof/nonstrict-pass-missing-verification-report/verify/report.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/events/events.jsonl +2 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/governance/policy.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/governance/revocations.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/manifest.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/verify/report.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-manifest-tamper/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/events/events.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/governance/policy.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/governance/revocations.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/manifest.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/verify/report.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-fail-unauthorized-signer/verify/verification_report.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/attestation/bundle_head_attestation.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/events/events.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/governance/global/events/events.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/governance/global/events/payload_material.jsonl +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/governance/global/snapshot.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/governance/policy.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/governance/revocations.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/governance/tenant/events/events.jsonl +0 -0
- package/conformance/v1/bundles/monthproof/strict-pass/governance/tenant/events/payload_material.jsonl +0 -0
- package/conformance/v1/bundles/monthproof/strict-pass/governance/tenant/snapshot.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/keys/public_keys.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/manifest.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/verify/report.json +1 -0
- package/conformance/v1/bundles/monthproof/strict-pass/verify/verification_report.json +1 -0
- package/conformance/v1/cases.json +381 -0
- package/conformance/v1/expected/closepack_nonstrict_pass_missing_sla_acceptance.json +9 -0
- package/conformance/v1/expected/closepack_strict_fail_embedded_invoice_fails.json +9 -0
- package/conformance/v1/expected/closepack_strict_fail_evidence_index_mismatch.json +9 -0
- package/conformance/v1/expected/closepack_strict_pass.json +9 -0
- package/conformance/v1/expected/financepack_strict_fail_missing_verification_report.json +9 -0
- package/conformance/v1/expected/financepack_strict_fail_on_warnings_tool_version_unknown.json +9 -0
- package/conformance/v1/expected/financepack_strict_fail_trust_roots_missing.json +9 -0
- package/conformance/v1/expected/financepack_strict_fail_trust_roots_wrong.json +9 -0
- package/conformance/v1/expected/financepack_strict_pass.json +9 -0
- package/conformance/v1/expected/invoicebundle_nonstrict_pass_missing_verification_report.json +9 -0
- package/conformance/v1/expected/invoicebundle_nonstrict_pass_unsigned_pricing_matrix_warning.json +9 -0
- package/conformance/v1/expected/invoicebundle_strict_fail_evidence_sha_mismatch.json +9 -0
- package/conformance/v1/expected/invoicebundle_strict_fail_invalid_pricing_matrix_signature.json +9 -0
- package/conformance/v1/expected/invoicebundle_strict_fail_invoice_total_mismatch.json +9 -0
- package/conformance/v1/expected/invoicebundle_strict_fail_missing_pricing_matrix_signature.json +9 -0
- package/conformance/v1/expected/invoicebundle_strict_fail_missing_verification_report.json +9 -0
- package/conformance/v1/expected/invoicebundle_strict_fail_pricing_code_unknown.json +9 -0
- package/conformance/v1/expected/invoicebundle_strict_pass.json +9 -0
- package/conformance/v1/expected/jobproof_nonstrict_pass_missing_verification_report.json +9 -0
- package/conformance/v1/expected/jobproof_strict_fail_manifest_tamper.json +9 -0
- package/conformance/v1/expected/jobproof_strict_fail_unauthorized_signer.json +9 -0
- package/conformance/v1/expected/jobproof_strict_pass.json +9 -0
- package/conformance/v1/expected/monthproof_nonstrict_pass_missing_verification_report.json +9 -0
- package/conformance/v1/expected/monthproof_strict_fail_manifest_tamper.json +9 -0
- package/conformance/v1/expected/monthproof_strict_fail_unauthorized_signer.json +9 -0
- package/conformance/v1/expected/monthproof_strict_pass.json +9 -0
- package/conformance/v1/expected/security_bundle_symlink_outside.json +9 -0
- package/conformance/v1/expected/security_manifest_case_collision.json +8 -0
- package/conformance/v1/expected/security_manifest_duplicate_paths.json +9 -0
- package/conformance/v1/expected/security_manifest_path_traversal.json +9 -0
- package/conformance/v1/lib/harness.mjs +78 -0
- package/conformance/v1/lib/mutations.mjs +61 -0
- package/conformance/v1/produce-cases.json +75 -0
- package/conformance/v1/producer/bad-plugin-invalid-provider.mjs +4 -0
- package/conformance/v1/producer/bad-plugin-no-export.mjs +3 -0
- package/conformance/v1/producer/fixture_keypairs.json +18 -0
- package/conformance/v1/producer/inmemory-signer-plugin.mjs +47 -0
- package/conformance/v1/producer/signer-stdio-bad-json.mjs +54 -0
- package/conformance/v1/producer/signer-stdio-partial-stdout-exit1.mjs +51 -0
- package/conformance/v1/producer/signer-stdio-stderr-only-exit1.mjs +46 -0
- package/conformance/v1/producer/signer-stdio-stub.mjs +134 -0
- package/conformance/v1/protocol-vectors/v1.json +81 -0
- package/conformance/v1/release-cases.json +111 -0
- package/conformance/v1/release-trust-quorum.json +15 -0
- package/conformance/v1/release-trust-revoked.json +16 -0
- package/conformance/v1/release-trust.json +15 -0
- package/conformance/v1/releases/release_fail_asset_hash_mismatch/a.tgz +1 -0
- package/conformance/v1/releases/release_fail_asset_hash_mismatch/b.tar.gz +1 -0
- package/conformance/v1/releases/release_fail_asset_hash_mismatch/release_index_v1.json +1 -0
- package/conformance/v1/releases/release_fail_asset_hash_mismatch/release_index_v1.sig +1 -0
- package/conformance/v1/releases/release_fail_missing_asset/a.tgz +1 -0
- package/conformance/v1/releases/release_fail_missing_asset/release_index_v1.json +1 -0
- package/conformance/v1/releases/release_fail_missing_asset/release_index_v1.sig +1 -0
- package/conformance/v1/releases/release_fail_signature_invalid/a.tgz +1 -0
- package/conformance/v1/releases/release_fail_signature_invalid/b.tar.gz +1 -0
- package/conformance/v1/releases/release_fail_signature_invalid/release_index_v1.json +1 -0
- package/conformance/v1/releases/release_fail_signature_invalid/release_index_v1.sig +1 -0
- package/conformance/v1/releases/release_pass/a.tgz +1 -0
- package/conformance/v1/releases/release_pass/b.tar.gz +1 -0
- package/conformance/v1/releases/release_pass/release_index_v1.json +1 -0
- package/conformance/v1/releases/release_pass/release_index_v1.sig +1 -0
- package/conformance/v1/run-produce.mjs +507 -0
- package/conformance/v1/run-release.mjs +129 -0
- package/conformance/v1/run.mjs +229 -0
- package/conformance/v1/trust.json +11 -0
- package/docker-compose.yml +154 -0
- package/package.json +98 -0
- package/packages/artifact-verify/src/bundle-path.js +60 -0
- package/packages/artifact-verify/src/canonical-json.js +48 -0
- package/packages/artifact-verify/src/close-pack-bundle.js +914 -0
- package/packages/artifact-verify/src/crypto.js +18 -0
- package/packages/artifact-verify/src/finance-pack-bundle.js +750 -0
- package/packages/artifact-verify/src/governance-policy.js +312 -0
- package/packages/artifact-verify/src/hash-file.js +38 -0
- package/packages/artifact-verify/src/index.js +100 -0
- package/packages/artifact-verify/src/invoice-bundle.js +865 -0
- package/packages/artifact-verify/src/job-proof-bundle.js +1996 -0
- package/packages/artifact-verify/src/map-with-concurrency.js +32 -0
- package/packages/artifact-verify/src/reconcile.js +135 -0
- package/packages/artifact-verify/src/release/release-index-lib.js +190 -0
- package/packages/artifact-verify/src/release/verify-release.js +187 -0
- package/packages/artifact-verify/src/revocation-list.js +119 -0
- package/packages/artifact-verify/src/safe-unzip.js +335 -0
- package/packages/artifact-verify/src/settlement-decision-report.js +61 -0
- package/packages/artifact-verify/src/timestamp-proof.js +49 -0
- package/packages/artifact-verify/src/tool-provenance.js +49 -0
- package/packages/artifact-verify/src/trust.js +54 -0
- package/packages/artifact-verify/src/verification-warnings.js +34 -0
- package/scripts/closepack/export.mjs +101 -0
- package/scripts/closepack/lib.mjs +1068 -0
- package/scripts/closepack/verify.mjs +65 -0
- package/scripts/init/capability.mjs +556 -0
- package/scripts/init/postinstall-sanity.mjs +18 -0
- package/services/finance-sink/README.md +37 -0
- package/services/finance-sink/package.json +6 -0
- package/services/finance-sink/src/ack-worker.js +152 -0
- package/services/finance-sink/src/config.js +176 -0
- package/services/finance-sink/src/dedupe-store.js +232 -0
- package/services/finance-sink/src/s3-store.js +139 -0
- package/services/finance-sink/src/server.js +391 -0
- package/services/receiver/README.md +49 -0
- package/services/receiver/package.json +6 -0
- package/services/receiver/src/ack-worker.js +166 -0
- package/services/receiver/src/config.js +178 -0
- package/services/receiver/src/dedupe-store.js +232 -0
- package/services/receiver/src/s3-store.js +111 -0
- package/services/receiver/src/server.js +304 -0
- package/src/agent/agent-sim.js +167 -0
- package/src/api/app.js +31794 -0
- package/src/api/http.js +124 -0
- package/src/api/maintenance.js +174 -0
- package/src/api/middleware/auth.js +105 -0
- package/src/api/middleware/authz.js +19 -0
- package/src/api/openapi.js +5684 -0
- package/src/api/outbox.js +93 -0
- package/src/api/persistence.js +628 -0
- package/src/api/server.js +100 -0
- package/src/api/store.js +2088 -0
- package/src/api/workers/artifacts.js +574 -0
- package/src/api/workers/deliveries.js +628 -0
- package/src/api/workers/proof.js +374 -0
- package/src/core/acceptance-criteria.js +78 -0
- package/src/core/access.js +130 -0
- package/src/core/agent-reputation.js +311 -0
- package/src/core/agent-runs.js +253 -0
- package/src/core/agent-wallets.js +883 -0
- package/src/core/allocations.js +160 -0
- package/src/core/artifact-verification-status.js +216 -0
- package/src/core/artifacts.js +938 -0
- package/src/core/assist.js +106 -0
- package/src/core/audit-export.js +68 -0
- package/src/core/auth.js +189 -0
- package/src/core/billing-plans.js +187 -0
- package/src/core/booking.js +268 -0
- package/src/core/cancellation.js +34 -0
- package/src/core/canonical-json.js +104 -0
- package/src/core/claims.js +152 -0
- package/src/core/close-pack-bundle.js +527 -0
- package/src/core/config.js +272 -0
- package/src/core/contract-compiler.js +68 -0
- package/src/core/contract-document.js +226 -0
- package/src/core/contract-selection.js +152 -0
- package/src/core/contracts.js +439 -0
- package/src/core/crypto.js +30 -0
- package/src/core/deterministic-zip.js +169 -0
- package/src/core/dispatch-events.js +113 -0
- package/src/core/dispatch.js +26 -0
- package/src/core/dispute-open-envelope.js +163 -0
- package/src/core/escrow-ledger.js +329 -0
- package/src/core/event-chain.js +114 -0
- package/src/core/event-policy.js +120 -0
- package/src/core/evidence-linker.js +93 -0
- package/src/core/evidence-store.js +286 -0
- package/src/core/evidence.js +119 -0
- package/src/core/failpoints.js +30 -0
- package/src/core/finance-account-map.js +59 -0
- package/src/core/finance-pack-bundle.js +554 -0
- package/src/core/funding-hold.js +185 -0
- package/src/core/gl-batch.js +107 -0
- package/src/core/governance-policy.js +174 -0
- package/src/core/governance.js +92 -0
- package/src/core/hold-exposure.js +74 -0
- package/src/core/idempotency.js +51 -0
- package/src/core/ids.js +21 -0
- package/src/core/incidents.js +75 -0
- package/src/core/insurer-reimbursements.js +58 -0
- package/src/core/interaction-directions.js +170 -0
- package/src/core/invoice-bundle.js +564 -0
- package/src/core/job-reducer.js +702 -0
- package/src/core/job-state-machine.js +266 -0
- package/src/core/journal-csv.js +94 -0
- package/src/core/ledger-postings-finance.js +31 -0
- package/src/core/ledger-postings.js +476 -0
- package/src/core/ledger.js +59 -0
- package/src/core/liveness.js +154 -0
- package/src/core/log.js +156 -0
- package/src/core/maintenance-locks.js +3 -0
- package/src/core/marketplace-kernel.js +243 -0
- package/src/core/metrics.js +133 -0
- package/src/core/money-rail-adapters.js +735 -0
- package/src/core/month-close-hold-policy.js +19 -0
- package/src/core/month-close.js +159 -0
- package/src/core/operator-cost.js +79 -0
- package/src/core/operator-coverage.js +46 -0
- package/src/core/operator-reducer.js +73 -0
- package/src/core/operators.js +52 -0
- package/src/core/ops-audit.js +45 -0
- package/src/core/party-statements.js +145 -0
- package/src/core/pilot-templates.js +26 -0
- package/src/core/policy.js +76 -0
- package/src/core/pricing.js +71 -0
- package/src/core/proof-bundle.js +1153 -0
- package/src/core/proof-events.js +88 -0
- package/src/core/proof-verifier.js +261 -0
- package/src/core/proof.js +46 -0
- package/src/core/protocol.js +105 -0
- package/src/core/quotas.js +32 -0
- package/src/core/reputation-event.js +203 -0
- package/src/core/rescheduling.js +51 -0
- package/src/core/retention.js +32 -0
- package/src/core/revocation-list.js +70 -0
- package/src/core/risk.js +383 -0
- package/src/core/robot-health.js +111 -0
- package/src/core/robot-reducer.js +198 -0
- package/src/core/robots.js +152 -0
- package/src/core/s3-presign.js +111 -0
- package/src/core/secrets.js +128 -0
- package/src/core/settlement-adjustment.js +151 -0
- package/src/core/settlement-kernel.js +405 -0
- package/src/core/settlement-policy.js +206 -0
- package/src/core/settlement-splits.js +46 -0
- package/src/core/signer-keys.js +33 -0
- package/src/core/skills.js +86 -0
- package/src/core/sla-events.js +229 -0
- package/src/core/sla-metering.js +169 -0
- package/src/core/sla-policy-templates.js +340 -0
- package/src/core/sla.js +29 -0
- package/src/core/statements.js +426 -0
- package/src/core/tenancy.js +55 -0
- package/src/core/timestamp-proof.js +36 -0
- package/src/core/tool-manifest.js +116 -0
- package/src/core/tool-provenance.js +36 -0
- package/src/core/url-safety.js +263 -0
- package/src/core/verification-warnings.js +53 -0
- package/src/core/zone-coverage.js +59 -0
- package/src/core/zones.js +8 -0
- package/src/core/zoneset.js +67 -0
- package/src/db/migrate.js +61 -0
- package/src/db/migrations/001_init.sql +92 -0
- package/src/db/migrations/002_robot_reservations.sql +23 -0
- package/src/db/migrations/003_idempotency_v2.sql +32 -0
- package/src/db/migrations/004_notifications.sql +12 -0
- package/src/db/migrations/005_multi_tenant.sql +106 -0
- package/src/db/migrations/006_contracts.sql +27 -0
- package/src/db/migrations/007_artifacts_deliveries_correlations.sql +53 -0
- package/src/db/migrations/008_delivery_ingest_hardening.sql +52 -0
- package/src/db/migrations/009_auth_keys.sql +21 -0
- package/src/db/migrations/010_signer_keys.sql +25 -0
- package/src/db/migrations/011_ops_audit.sql +33 -0
- package/src/db/migrations/012_retention.sql +16 -0
- package/src/db/migrations/013_perf_indexes.sql +18 -0
- package/src/db/migrations/014_contracts_v2.sql +68 -0
- package/src/db/migrations/015_parties.sql +16 -0
- package/src/db/migrations/016_ledger_allocations.sql +18 -0
- package/src/db/migrations/017_party_statements.sql +31 -0
- package/src/db/migrations/018_finance_account_map.sql +12 -0
- package/src/db/migrations/019_ledger_allocations_account_id.sql +7 -0
- package/src/db/migrations/020_artifacts_source_event_unique.sql +10 -0
- package/src/db/migrations/021_artifacts_by_job_created_at_id.sql +6 -0
- package/src/db/migrations/022_governance_uniqueness.sql +28 -0
- package/src/db/migrations/023_marketplace_tasks.sql +45 -0
- package/src/db/migrations/024_agent_runtime_state.sql +70 -0
- package/src/db/migrations/025_tenant_settlement_policies.sql +19 -0
- package/src/db/migrations/026_money_rails_billable_events.sql +82 -0
- package/src/db/migrations/027_tenant_billing_config.sql +10 -0
- package/src/db/migrations/028_marketplace_rfq_storage.sql +121 -0
- package/src/db/pg.js +123 -0
- package/src/db/store-pg.js +6465 -0
|
@@ -0,0 +1,750 @@
|
|
|
1
|
+
import fs from "node:fs/promises";
|
|
2
|
+
import path from "node:path";
|
|
3
|
+
|
|
4
|
+
import { canonicalJsonStringify } from "./canonical-json.js";
|
|
5
|
+
import { sha256HexUtf8, verifyHashHexEd25519 } from "./crypto.js";
|
|
6
|
+
import { hashFile } from "./hash-file.js";
|
|
7
|
+
import { mapWithConcurrency } from "./map-with-concurrency.js";
|
|
8
|
+
import { prevalidateManifestFileEntries, resolveBundlePath } from "./bundle-path.js";
|
|
9
|
+
import {
|
|
10
|
+
GOVERNANCE_POLICY_SCHEMA_V2,
|
|
11
|
+
authorizeServerSignerForPolicy,
|
|
12
|
+
parseGovernancePolicyV1,
|
|
13
|
+
parseGovernancePolicyV2,
|
|
14
|
+
verifyGovernancePolicyV2Signature
|
|
15
|
+
} from "./governance-policy.js";
|
|
16
|
+
import { deriveKeyTimelineFromRevocationList, parseRevocationListV1, verifyRevocationListV1Signature } from "./revocation-list.js";
|
|
17
|
+
import { verifyTimestampProofV1 } from "./timestamp-proof.js";
|
|
18
|
+
import { trustedGovernanceRootKeysFromEnv, trustedTimeAuthorityKeysFromEnv } from "./trust.js";
|
|
19
|
+
import { verifyMonthProofBundleDir } from "./job-proof-bundle.js";
|
|
20
|
+
import { reconcileGlBatchAgainstPartyStatements } from "./reconcile.js";
|
|
21
|
+
import { VERIFICATION_WARNING_CODE, validateVerificationWarnings } from "./verification-warnings.js";
|
|
22
|
+
|
|
23
|
+
export const FINANCE_PACK_BUNDLE_TYPE_V1 = "FinancePackBundle.v1";
|
|
24
|
+
export const FINANCE_PACK_BUNDLE_MANIFEST_SCHEMA_V1 = "FinancePackBundleManifest.v1";
|
|
25
|
+
export const BUNDLE_HEAD_ATTESTATION_SCHEMA_V1 = "BundleHeadAttestation.v1";
|
|
26
|
+
|
|
27
|
+
const DEFAULT_HASH_CONCURRENCY = 16;
|
|
28
|
+
|
|
29
|
+
async function readJson(filepath) {
|
|
30
|
+
const raw = await fs.readFile(filepath, "utf8");
|
|
31
|
+
return JSON.parse(raw);
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
function normalizeHashConcurrency(value) {
|
|
35
|
+
if (value === null || value === undefined) return DEFAULT_HASH_CONCURRENCY;
|
|
36
|
+
if (!Number.isInteger(value) || value < 1) throw new TypeError("hashConcurrency must be a positive integer");
|
|
37
|
+
return value;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
async function verifyManifestFileHashes({ dir, manifestFiles, warnings, hashConcurrency }) {
|
|
41
|
+
const entries = [];
|
|
42
|
+
const seen = new Set();
|
|
43
|
+
for (const f of manifestFiles ?? []) {
|
|
44
|
+
if (!f || typeof f !== "object") continue;
|
|
45
|
+
const name = typeof f.name === "string" ? f.name : null;
|
|
46
|
+
const expectedSha = typeof f.sha256 === "string" ? f.sha256 : null;
|
|
47
|
+
if (!name || !expectedSha) continue;
|
|
48
|
+
if (seen.has(name)) return { ok: false, error: "MANIFEST_DUPLICATE_PATH", name, warnings };
|
|
49
|
+
seen.add(name);
|
|
50
|
+
const rp = resolveBundlePath({ bundleDir: dir, name });
|
|
51
|
+
if (!rp.ok) return { ok: false, error: rp.error, name: rp.name ?? name, reason: rp.reason ?? null, warnings };
|
|
52
|
+
entries.push({ name, expectedSha, fp: rp.path });
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
const actualByIndex = await mapWithConcurrency(entries, hashConcurrency, async (e) => {
|
|
56
|
+
try {
|
|
57
|
+
const st = await fs.lstat(e.fp);
|
|
58
|
+
if (st.isSymbolicLink()) return { ok: false, error: { code: "SYMLINK" } };
|
|
59
|
+
if (!st.isFile()) return { ok: false, error: { code: "NOT_FILE" } };
|
|
60
|
+
const actualSha = await hashFile(e.fp, { algo: "sha256" });
|
|
61
|
+
return { ok: true, actualSha };
|
|
62
|
+
} catch (err) {
|
|
63
|
+
return { ok: false, error: err };
|
|
64
|
+
}
|
|
65
|
+
});
|
|
66
|
+
|
|
67
|
+
for (let i = 0; i < entries.length; i += 1) {
|
|
68
|
+
const e = entries[i];
|
|
69
|
+
const res = actualByIndex[i];
|
|
70
|
+
if (!res?.ok) {
|
|
71
|
+
if (res?.error?.code === "SYMLINK") return { ok: false, error: "MANIFEST_SYMLINK_FORBIDDEN", name: e.name, warnings };
|
|
72
|
+
const code = res?.error?.code ?? null;
|
|
73
|
+
if (code === "ENOENT") return { ok: false, error: "missing file", name: e.name, warnings };
|
|
74
|
+
return {
|
|
75
|
+
ok: false,
|
|
76
|
+
error: "failed to hash file",
|
|
77
|
+
name: e.name,
|
|
78
|
+
warnings,
|
|
79
|
+
detail: { code, message: res?.error?.message ?? String(res?.error ?? "") }
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
if (res.actualSha !== e.expectedSha) return { ok: false, error: "sha256 mismatch", name: e.name, expected: e.expectedSha, actual: res.actualSha, warnings };
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
return { ok: true };
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
function stripManifestHash(manifestWithHash) {
|
|
89
|
+
const { manifestHash: _ignored, ...rest } = manifestWithHash ?? {};
|
|
90
|
+
return rest;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
function verifyArtifactTypeAndHash({ artifact, expectedType }) {
|
|
94
|
+
if (!artifact || typeof artifact !== "object" || Array.isArray(artifact)) return { ok: false, error: "invalid artifact JSON" };
|
|
95
|
+
const artifactType = typeof artifact.artifactType === "string" ? artifact.artifactType : null;
|
|
96
|
+
const schemaVersion = typeof artifact.schemaVersion === "string" ? artifact.schemaVersion : null;
|
|
97
|
+
const artifactHash = typeof artifact.artifactHash === "string" ? artifact.artifactHash : null;
|
|
98
|
+
if (artifactType !== expectedType) return { ok: false, error: "artifactType mismatch", expected: expectedType, actual: artifactType };
|
|
99
|
+
if (schemaVersion && schemaVersion !== expectedType) return { ok: false, error: "schemaVersion mismatch", expected: expectedType, actual: schemaVersion };
|
|
100
|
+
if (!artifactHash) return { ok: false, error: "missing artifactHash" };
|
|
101
|
+
const { artifactHash: _ignored, ...core } = artifact;
|
|
102
|
+
const expectedHash = sha256HexUtf8(canonicalJsonStringify(core));
|
|
103
|
+
if (expectedHash !== artifactHash) return { ok: false, error: "artifactHash mismatch", expected: expectedHash, actual: artifactHash };
|
|
104
|
+
return { ok: true, artifactType, artifactHash };
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
function stripVerificationReportSig(report) {
|
|
108
|
+
const { reportHash: _h, signature: _sig, ...rest } = report ?? {};
|
|
109
|
+
return rest;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
function stripAttestationSig(attestation) {
|
|
113
|
+
const { signature: _sig, attestationHash: _hash, ...rest } = attestation ?? {};
|
|
114
|
+
return rest;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
function parsePublicKeysV1(keysJson) {
|
|
118
|
+
const publicKeyByKeyId = new Map();
|
|
119
|
+
const keyMetaByKeyId = new Map();
|
|
120
|
+
const schemaVersion = typeof keysJson?.schemaVersion === "string" ? keysJson.schemaVersion : null;
|
|
121
|
+
if (schemaVersion !== "PublicKeys.v1") return { ok: false, error: "unsupported keys schemaVersion", schemaVersion };
|
|
122
|
+
const keys = Array.isArray(keysJson?.keys) ? keysJson.keys : [];
|
|
123
|
+
for (const k of keys) {
|
|
124
|
+
if (!k || typeof k !== "object") continue;
|
|
125
|
+
const keyId = typeof k.keyId === "string" && k.keyId.trim() ? k.keyId : null;
|
|
126
|
+
const publicKeyPem = typeof k.publicKeyPem === "string" && k.publicKeyPem.trim() ? k.publicKeyPem : null;
|
|
127
|
+
if (!keyId || !publicKeyPem) continue;
|
|
128
|
+
publicKeyByKeyId.set(keyId, publicKeyPem);
|
|
129
|
+
keyMetaByKeyId.set(keyId, k);
|
|
130
|
+
}
|
|
131
|
+
return { ok: true, publicKeyByKeyId, keyMetaByKeyId };
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
function parseJsonl(text) {
|
|
135
|
+
const out = [];
|
|
136
|
+
const lines = String(text ?? "").split("\n");
|
|
137
|
+
for (const line of lines) {
|
|
138
|
+
const trimmed = line.trim();
|
|
139
|
+
if (!trimmed) continue;
|
|
140
|
+
out.push(JSON.parse(trimmed));
|
|
141
|
+
}
|
|
142
|
+
return out;
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
function safeIsoToMs(value) {
|
|
146
|
+
const t = Date.parse(String(value ?? ""));
|
|
147
|
+
return Number.isFinite(t) ? t : NaN;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
function keyEffectiveWindowMs(meta) {
|
|
151
|
+
const validFromMs = safeIsoToMs(meta?.validFrom);
|
|
152
|
+
const validToMs = safeIsoToMs(meta?.validTo);
|
|
153
|
+
const rotatedAtMs = safeIsoToMs(meta?.rotatedAt);
|
|
154
|
+
const revokedAtMs = safeIsoToMs(meta?.revokedAt);
|
|
155
|
+
return { validFromMs, validToMs, rotatedAtMs, revokedAtMs };
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
function isServerKeyUsableAtForAttestation({ meta, atIso }) {
|
|
159
|
+
if (!meta || typeof meta !== "object") return { ok: true };
|
|
160
|
+
const atMs = safeIsoToMs(atIso);
|
|
161
|
+
if (!Number.isFinite(atMs)) return { ok: true };
|
|
162
|
+
const { validFromMs, validToMs, rotatedAtMs, revokedAtMs } = keyEffectiveWindowMs(meta);
|
|
163
|
+
if (Number.isFinite(validFromMs) && atMs < validFromMs) return { ok: false, reason: "KEY_NOT_YET_VALID", boundary: meta.validFrom };
|
|
164
|
+
if (Number.isFinite(validToMs) && atMs > validToMs) return { ok: false, reason: "KEY_EXPIRED", boundary: meta.validTo };
|
|
165
|
+
if (Number.isFinite(revokedAtMs) && atMs > revokedAtMs) return { ok: false, reason: "KEY_REVOKED", boundary: meta.revokedAt };
|
|
166
|
+
if (Number.isFinite(rotatedAtMs) && atMs > rotatedAtMs) return { ok: false, reason: "KEY_ROTATED", boundary: meta.rotatedAt };
|
|
167
|
+
return { ok: true };
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
function effectiveSigningTimeFromTimestampProof({ documentCoreWithProof, fallbackSignedAt, trustedTimeAuthorities }) {
|
|
171
|
+
if (!(trustedTimeAuthorities instanceof Map)) return { ok: true, effectiveSignedAt: fallbackSignedAt, trustworthy: false, proof: null };
|
|
172
|
+
const check = verifyTimestampProofV1({ documentCoreWithProof, trustedPublicKeyByKeyId: trustedTimeAuthorities });
|
|
173
|
+
if (check.ok) return { ok: true, effectiveSignedAt: check.timestamp, trustworthy: true, proof: check };
|
|
174
|
+
return { ok: true, effectiveSignedAt: fallbackSignedAt, trustworthy: false, proof: check };
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
function enforceProspectiveKeyTimeline({ signerKeyId, effectiveSignedAt, trustworthyTime, timelineRow }) {
|
|
178
|
+
const atMs = safeIsoToMs(effectiveSignedAt);
|
|
179
|
+
if (!Number.isFinite(atMs)) return { ok: true };
|
|
180
|
+
if (!timelineRow || typeof timelineRow !== "object") return { ok: true };
|
|
181
|
+
|
|
182
|
+
const revokedAt = typeof timelineRow.revokedAt === "string" && timelineRow.revokedAt.trim() ? timelineRow.revokedAt.trim() : null;
|
|
183
|
+
const rotatedAt = typeof timelineRow.rotatedAt === "string" && timelineRow.rotatedAt.trim() ? timelineRow.rotatedAt.trim() : null;
|
|
184
|
+
const validFrom = typeof timelineRow.validFrom === "string" && timelineRow.validFrom.trim() ? timelineRow.validFrom.trim() : null;
|
|
185
|
+
|
|
186
|
+
if (validFrom) {
|
|
187
|
+
const vfMs = safeIsoToMs(validFrom);
|
|
188
|
+
if (Number.isFinite(vfMs) && atMs < vfMs) return { ok: false, error: "SIGNER_NOT_YET_VALID", signerKeyId, boundary: validFrom };
|
|
189
|
+
}
|
|
190
|
+
|
|
191
|
+
if (revokedAt) {
|
|
192
|
+
const rMs = safeIsoToMs(revokedAt);
|
|
193
|
+
if (Number.isFinite(rMs)) {
|
|
194
|
+
if (atMs >= rMs) return { ok: false, error: "SIGNER_REVOKED", signerKeyId, boundary: revokedAt };
|
|
195
|
+
if (!trustworthyTime) return { ok: false, error: "SIGNING_TIME_UNPROVABLE", signerKeyId, boundary: revokedAt };
|
|
196
|
+
}
|
|
197
|
+
}
|
|
198
|
+
if (rotatedAt) {
|
|
199
|
+
const rtMs = safeIsoToMs(rotatedAt);
|
|
200
|
+
if (Number.isFinite(rtMs)) {
|
|
201
|
+
if (atMs >= rtMs) return { ok: false, error: "SIGNER_ROTATED", signerKeyId, boundary: rotatedAt };
|
|
202
|
+
if (!trustworthyTime) return { ok: false, error: "SIGNING_TIME_UNPROVABLE", signerKeyId, boundary: rotatedAt };
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
return { ok: true };
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
function normalizedPurpose(meta) {
|
|
209
|
+
if (!meta || typeof meta !== "object") return null;
|
|
210
|
+
const p = typeof meta.purpose === "string" && meta.purpose.trim() ? meta.purpose.trim().toLowerCase() : null;
|
|
211
|
+
return p || null;
|
|
212
|
+
}
|
|
213
|
+
|
|
214
|
+
function deriveServerKeyTimelineFromGovernanceEvents(events) {
|
|
215
|
+
const derived = new Map(); // keyId -> { validFrom, rotatedAt, revokedAt, serverGoverned }
|
|
216
|
+
for (const e of Array.isArray(events) ? events : []) {
|
|
217
|
+
if (!e || typeof e !== "object") continue;
|
|
218
|
+
const type = String(e.type ?? "");
|
|
219
|
+
const at = typeof e.at === "string" && e.at.trim() ? e.at : null;
|
|
220
|
+
const p = e.payload ?? null;
|
|
221
|
+
if (!p || typeof p !== "object") continue;
|
|
222
|
+
|
|
223
|
+
if (type === "SERVER_SIGNER_KEY_REGISTERED") {
|
|
224
|
+
const keyId = typeof p.keyId === "string" && p.keyId.trim() ? p.keyId : null;
|
|
225
|
+
const registeredAt = typeof p.registeredAt === "string" && p.registeredAt.trim() ? p.registeredAt : at;
|
|
226
|
+
if (!keyId || !registeredAt) continue;
|
|
227
|
+
const row = derived.get(keyId) ?? {};
|
|
228
|
+
if (!row.validFrom) row.validFrom = registeredAt;
|
|
229
|
+
row.serverGoverned = true;
|
|
230
|
+
derived.set(keyId, row);
|
|
231
|
+
}
|
|
232
|
+
|
|
233
|
+
if (type === "SERVER_SIGNER_KEY_ROTATED") {
|
|
234
|
+
const oldKeyId = typeof p.oldKeyId === "string" && p.oldKeyId.trim() ? p.oldKeyId : null;
|
|
235
|
+
const newKeyId = typeof p.newKeyId === "string" && p.newKeyId.trim() ? p.newKeyId : null;
|
|
236
|
+
const rotatedAt = typeof p.rotatedAt === "string" && p.rotatedAt.trim() ? p.rotatedAt : at;
|
|
237
|
+
if (!rotatedAt) continue;
|
|
238
|
+
if (oldKeyId) {
|
|
239
|
+
const row = derived.get(oldKeyId) ?? {};
|
|
240
|
+
row.rotatedAt = rotatedAt;
|
|
241
|
+
row.serverGoverned = true;
|
|
242
|
+
derived.set(oldKeyId, row);
|
|
243
|
+
}
|
|
244
|
+
if (newKeyId) {
|
|
245
|
+
const row = derived.get(newKeyId) ?? {};
|
|
246
|
+
if (!row.validFrom) row.validFrom = rotatedAt;
|
|
247
|
+
row.serverGoverned = true;
|
|
248
|
+
derived.set(newKeyId, row);
|
|
249
|
+
}
|
|
250
|
+
}
|
|
251
|
+
|
|
252
|
+
if (type === "SERVER_SIGNER_KEY_REVOKED") {
|
|
253
|
+
const keyId = typeof p.keyId === "string" && p.keyId.trim() ? p.keyId : null;
|
|
254
|
+
const revokedAt = typeof p.revokedAt === "string" && p.revokedAt.trim() ? p.revokedAt : at;
|
|
255
|
+
if (!keyId || !revokedAt) continue;
|
|
256
|
+
const row = derived.get(keyId) ?? {};
|
|
257
|
+
row.revokedAt = revokedAt;
|
|
258
|
+
row.serverGoverned = true;
|
|
259
|
+
derived.set(keyId, row);
|
|
260
|
+
}
|
|
261
|
+
}
|
|
262
|
+
return derived;
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
function applyDerivedServerTimeline({ keyMetaByKeyId, derived }) {
|
|
266
|
+
const next = new Map(keyMetaByKeyId);
|
|
267
|
+
for (const [keyId, timeline] of derived.entries()) {
|
|
268
|
+
const existing = next.get(keyId) ?? null;
|
|
269
|
+
if (!existing || typeof existing !== "object") continue;
|
|
270
|
+
next.set(keyId, {
|
|
271
|
+
...existing,
|
|
272
|
+
validFrom: timeline.validFrom ?? existing.validFrom ?? null,
|
|
273
|
+
rotatedAt: timeline.rotatedAt ?? existing.rotatedAt ?? null,
|
|
274
|
+
revokedAt: timeline.revokedAt ?? existing.revokedAt ?? null,
|
|
275
|
+
serverGoverned: timeline.serverGoverned === true ? true : existing.serverGoverned === true
|
|
276
|
+
});
|
|
277
|
+
}
|
|
278
|
+
return next;
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
function verifyBundleHeadAttestationV1({
|
|
282
|
+
attestation,
|
|
283
|
+
expectedManifestHash,
|
|
284
|
+
expectedTenantId,
|
|
285
|
+
expectedPeriod,
|
|
286
|
+
monthManifestHash,
|
|
287
|
+
monthAttestationHash,
|
|
288
|
+
governancePolicy,
|
|
289
|
+
revocationTimelineByKeyId,
|
|
290
|
+
trustedTimeAuthorities,
|
|
291
|
+
publicKeyByKeyId,
|
|
292
|
+
keyMetaByKeyId,
|
|
293
|
+
strict
|
|
294
|
+
}) {
|
|
295
|
+
if (!attestation || typeof attestation !== "object" || Array.isArray(attestation)) return { ok: false, error: "invalid bundle head attestation JSON" };
|
|
296
|
+
if (String(attestation.schemaVersion ?? "") !== BUNDLE_HEAD_ATTESTATION_SCHEMA_V1) return { ok: false, error: "unsupported attestation schemaVersion" };
|
|
297
|
+
if (String(attestation.kind ?? "") !== FINANCE_PACK_BUNDLE_TYPE_V1) return { ok: false, error: "attestation kind mismatch", expected: FINANCE_PACK_BUNDLE_TYPE_V1, actual: attestation.kind ?? null };
|
|
298
|
+
if (String(attestation.tenantId ?? "") !== String(expectedTenantId ?? "")) return { ok: false, error: "attestation tenantId mismatch", expected: expectedTenantId ?? null, actual: attestation.tenantId ?? null };
|
|
299
|
+
if (String(attestation.scope?.period ?? "") !== String(expectedPeriod ?? "")) return { ok: false, error: "attestation scope.period mismatch", expected: expectedPeriod ?? null, actual: attestation.scope?.period ?? null };
|
|
300
|
+
if (String(attestation.manifestHash ?? "") !== String(expectedManifestHash ?? "")) return { ok: false, error: "attestation manifestHash mismatch", expected: expectedManifestHash ?? null, actual: attestation.manifestHash ?? null };
|
|
301
|
+
|
|
302
|
+
const signerKeyId = typeof attestation.signerKeyId === "string" && attestation.signerKeyId.trim() ? attestation.signerKeyId : null;
|
|
303
|
+
const signature = typeof attestation.signature === "string" && attestation.signature.trim() ? attestation.signature : null;
|
|
304
|
+
const signedAt = typeof attestation.signedAt === "string" && attestation.signedAt.trim() ? attestation.signedAt : null;
|
|
305
|
+
if (strict && (!signerKeyId || !signature || !signedAt)) return { ok: false, error: "attestation missing signature fields", signerKeyId, signature: Boolean(signature), signedAt };
|
|
306
|
+
|
|
307
|
+
const attestationCore = stripAttestationSig(attestation);
|
|
308
|
+
const expectedHash = sha256HexUtf8(canonicalJsonStringify(attestationCore));
|
|
309
|
+
const declaredHash = typeof attestation.attestationHash === "string" && attestation.attestationHash.trim() ? attestation.attestationHash : null;
|
|
310
|
+
if (declaredHash && declaredHash !== expectedHash) return { ok: false, error: "attestationHash mismatch", expected: expectedHash, actual: declaredHash };
|
|
311
|
+
|
|
312
|
+
if (signature && signerKeyId) {
|
|
313
|
+
const publicKeyPem = publicKeyByKeyId.get(signerKeyId) ?? null;
|
|
314
|
+
if (!publicKeyPem) return { ok: false, error: "unknown attestation signerKeyId", signerKeyId };
|
|
315
|
+
const okSig = verifyHashHexEd25519({ hashHex: expectedHash, signatureBase64: signature, publicKeyPem });
|
|
316
|
+
if (!okSig) return { ok: false, error: "attestation signature invalid", signerKeyId };
|
|
317
|
+
if (strict) {
|
|
318
|
+
const meta = keyMetaByKeyId.get(signerKeyId) ?? null;
|
|
319
|
+
const auth = authorizeServerSignerForPolicy({
|
|
320
|
+
policy: governancePolicy,
|
|
321
|
+
documentKind: "bundle_head_attestation",
|
|
322
|
+
subjectType: FINANCE_PACK_BUNDLE_TYPE_V1,
|
|
323
|
+
signerKeyId,
|
|
324
|
+
signerScope: "global",
|
|
325
|
+
keyMeta: meta
|
|
326
|
+
});
|
|
327
|
+
if (!auth.ok) return { ok: false, error: "attestation signer not authorized", detail: auth, signerKeyId };
|
|
328
|
+
if (!(typeof meta?.validFrom === "string" && meta.validFrom.trim())) return { ok: false, error: "attestation signer key missing validFrom", signerKeyId };
|
|
329
|
+
if (revocationTimelineByKeyId instanceof Map) {
|
|
330
|
+
const time = effectiveSigningTimeFromTimestampProof({ documentCoreWithProof: attestationCore, fallbackSignedAt: signedAt, trustedTimeAuthorities });
|
|
331
|
+
const effectiveSignedAt = time.effectiveSignedAt;
|
|
332
|
+
const usable = isServerKeyUsableAtForAttestation({ meta, atIso: effectiveSignedAt });
|
|
333
|
+
if (!usable.ok) return { ok: false, error: "attestation signer key not valid", signerKeyId, reason: usable.reason, boundary: usable.boundary ?? null };
|
|
334
|
+
const row = revocationTimelineByKeyId.get(signerKeyId) ?? null;
|
|
335
|
+
const timelineCheck = enforceProspectiveKeyTimeline({ signerKeyId, effectiveSignedAt, trustworthyTime: time.trustworthy, timelineRow: row });
|
|
336
|
+
if (!timelineCheck.ok) return { ok: false, error: timelineCheck.error, detail: { ...timelineCheck, timeProof: time.proof ?? null }, signerKeyId };
|
|
337
|
+
} else {
|
|
338
|
+
const usable = isServerKeyUsableAtForAttestation({ meta, atIso: signedAt });
|
|
339
|
+
if (!usable.ok) return { ok: false, error: "attestation signer key not valid", signerKeyId, reason: usable.reason, boundary: usable.boundary ?? null };
|
|
340
|
+
}
|
|
341
|
+
}
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
const heads = attestation.heads ?? null;
|
|
345
|
+
if (!heads || typeof heads !== "object" || Array.isArray(heads)) return { ok: false, error: "attestation missing heads" };
|
|
346
|
+
const mp = heads.monthProof ?? null;
|
|
347
|
+
if (!mp || typeof mp !== "object" || Array.isArray(mp)) return { ok: false, error: "attestation missing heads.monthProof" };
|
|
348
|
+
if (String(mp.manifestHash ?? "") !== String(monthManifestHash ?? "")) return { ok: false, error: "attestation monthProof.manifestHash mismatch", expected: monthManifestHash ?? null, actual: mp.manifestHash ?? null };
|
|
349
|
+
if (monthAttestationHash && String(mp.attestationHash ?? "") !== String(monthAttestationHash ?? "")) {
|
|
350
|
+
return { ok: false, error: "attestation monthProof.attestationHash mismatch", expected: monthAttestationHash ?? null, actual: mp.attestationHash ?? null };
|
|
351
|
+
}
|
|
352
|
+
|
|
353
|
+
return { ok: true, attestationHash: expectedHash, signerKeyId, signedAt };
|
|
354
|
+
}
|
|
355
|
+
|
|
356
|
+
function verifyVerificationReportV1({ report, expectedManifestHash, monthPublicKeys, governancePolicy, revocationTimelineByKeyId, trustedTimeAuthorities, strict }) {
|
|
357
|
+
if (!report || typeof report !== "object" || Array.isArray(report)) return { ok: false, error: "invalid verification report JSON" };
|
|
358
|
+
if (String(report.schemaVersion ?? "") !== "VerificationReport.v1") return { ok: false, error: "unsupported verification report schemaVersion" };
|
|
359
|
+
if (String(report.profile ?? "") !== "strict") return { ok: false, error: "unsupported verification report profile", profile: report.profile ?? null };
|
|
360
|
+
const warningsCheck = validateVerificationWarnings(report.warnings ?? null);
|
|
361
|
+
if (!warningsCheck.ok) return { ok: false, error: `verification report warnings invalid: ${warningsCheck.error}`, detail: warningsCheck };
|
|
362
|
+
|
|
363
|
+
const subject = report.subject ?? null;
|
|
364
|
+
if (!subject || typeof subject !== "object" || Array.isArray(subject)) return { ok: false, error: "invalid verification report subject" };
|
|
365
|
+
if (String(subject.type ?? "") !== FINANCE_PACK_BUNDLE_TYPE_V1) return { ok: false, error: "verification report subject.type mismatch", expected: FINANCE_PACK_BUNDLE_TYPE_V1, actual: subject.type ?? null };
|
|
366
|
+
if (String(subject.manifestHash ?? "") !== String(expectedManifestHash ?? "")) {
|
|
367
|
+
return { ok: false, error: "verification report subject.manifestHash mismatch", expected: expectedManifestHash ?? null, actual: subject.manifestHash ?? null };
|
|
368
|
+
}
|
|
369
|
+
|
|
370
|
+
if (strict) {
|
|
371
|
+
const b = report.bundleHeadAttestation ?? null;
|
|
372
|
+
if (!b || typeof b !== "object" || Array.isArray(b)) return { ok: false, error: "verification report missing bundleHeadAttestation" };
|
|
373
|
+
const declared = typeof b.attestationHash === "string" && b.attestationHash.trim() ? b.attestationHash : null;
|
|
374
|
+
if (!declared) return { ok: false, error: "verification report bundleHeadAttestation.attestationHash missing" };
|
|
375
|
+
}
|
|
376
|
+
|
|
377
|
+
const reportCore = stripVerificationReportSig(report);
|
|
378
|
+
const expectedReportHash = sha256HexUtf8(canonicalJsonStringify(reportCore));
|
|
379
|
+
const actualReportHash = typeof report.reportHash === "string" ? report.reportHash : null;
|
|
380
|
+
if (!actualReportHash) return { ok: false, error: "verification report missing reportHash" };
|
|
381
|
+
if (expectedReportHash !== actualReportHash) {
|
|
382
|
+
return { ok: false, error: "verification report reportHash mismatch", expected: expectedReportHash, actual: actualReportHash };
|
|
383
|
+
}
|
|
384
|
+
|
|
385
|
+
const signature = typeof report.signature === "string" && report.signature.trim() ? report.signature : null;
|
|
386
|
+
const signerKeyId = typeof report.signerKeyId === "string" && report.signerKeyId.trim() ? report.signerKeyId : null;
|
|
387
|
+
const signedAt = typeof report.signedAt === "string" && report.signedAt.trim() ? report.signedAt : null;
|
|
388
|
+
if (strict && (!signature || !signerKeyId || !signedAt)) {
|
|
389
|
+
return { ok: false, error: "verification report missing signature", signature: Boolean(signature), signerKeyId, signedAt };
|
|
390
|
+
}
|
|
391
|
+
|
|
392
|
+
// Optional signer provenance object must be internally consistent when present.
|
|
393
|
+
const signer = report.signer ?? null;
|
|
394
|
+
if (signer !== null && signer !== undefined) {
|
|
395
|
+
if (!signer || typeof signer !== "object" || Array.isArray(signer)) return { ok: false, error: "verification report signer must be an object" };
|
|
396
|
+
if (typeof signer.keyId !== "string" || !signer.keyId.trim()) return { ok: false, error: "verification report signer.keyId missing" };
|
|
397
|
+
if (signerKeyId && signer.keyId !== signerKeyId) return { ok: false, error: "verification report signer.keyId mismatch", expected: signerKeyId, actual: signer.keyId };
|
|
398
|
+
if (signer.scope !== undefined && signer.scope !== null) {
|
|
399
|
+
const scope = String(signer.scope);
|
|
400
|
+
if (scope !== "global" && scope !== "tenant") return { ok: false, error: "verification report signer.scope invalid", scope };
|
|
401
|
+
}
|
|
402
|
+
}
|
|
403
|
+
|
|
404
|
+
if (signature && signerKeyId) {
|
|
405
|
+
const publicKeyPem = monthPublicKeys?.publicKeyByKeyId?.get?.(signerKeyId) ?? null;
|
|
406
|
+
if (!publicKeyPem) return { ok: false, error: "verification report signerKeyId not found in month keys", signerKeyId };
|
|
407
|
+
const ok = verifyHashHexEd25519({ hashHex: actualReportHash, signatureBase64: signature, publicKeyPem });
|
|
408
|
+
if (!ok) return { ok: false, error: "verification report signature invalid", signerKeyId };
|
|
409
|
+
|
|
410
|
+
if (strict) {
|
|
411
|
+
const meta = monthPublicKeys?.keyMetaByKeyId?.get?.(signerKeyId) ?? null;
|
|
412
|
+
const auth = authorizeServerSignerForPolicy({
|
|
413
|
+
policy: governancePolicy,
|
|
414
|
+
documentKind: "verification_report",
|
|
415
|
+
subjectType: FINANCE_PACK_BUNDLE_TYPE_V1,
|
|
416
|
+
signerKeyId,
|
|
417
|
+
signerScope: signer?.scope ?? "global",
|
|
418
|
+
keyMeta: meta
|
|
419
|
+
});
|
|
420
|
+
if (!auth.ok) return { ok: false, error: "verification report signer not authorized", detail: auth, signerKeyId };
|
|
421
|
+
if (!(typeof meta?.validFrom === "string" && meta.validFrom.trim())) return { ok: false, error: "verification report signer key missing validFrom", signerKeyId };
|
|
422
|
+
if (revocationTimelineByKeyId instanceof Map) {
|
|
423
|
+
const time = effectiveSigningTimeFromTimestampProof({ documentCoreWithProof: reportCore, fallbackSignedAt: signedAt, trustedTimeAuthorities });
|
|
424
|
+
const effectiveSignedAt = time.effectiveSignedAt;
|
|
425
|
+
const usable = isServerKeyUsableAtForAttestation({ meta, atIso: effectiveSignedAt });
|
|
426
|
+
if (!usable.ok) return { ok: false, error: "verification report signer key not valid", signerKeyId, reason: usable.reason, boundary: usable.boundary ?? null };
|
|
427
|
+
const row = revocationTimelineByKeyId.get(signerKeyId) ?? null;
|
|
428
|
+
const timelineCheck = enforceProspectiveKeyTimeline({ signerKeyId, effectiveSignedAt, trustworthyTime: time.trustworthy, timelineRow: row });
|
|
429
|
+
if (!timelineCheck.ok) return { ok: false, error: timelineCheck.error, detail: { ...timelineCheck, timeProof: time.proof ?? null }, signerKeyId };
|
|
430
|
+
} else {
|
|
431
|
+
const usable = isServerKeyUsableAtForAttestation({ meta, atIso: signedAt });
|
|
432
|
+
if (!usable.ok) return { ok: false, error: "verification report signer key not valid", signerKeyId, reason: usable.reason, boundary: usable.boundary ?? null };
|
|
433
|
+
}
|
|
434
|
+
}
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
return { ok: true, reportHash: actualReportHash, signerKeyId: signerKeyId ?? null };
|
|
438
|
+
}
|
|
439
|
+
|
|
440
|
+
export async function verifyFinancePackBundleDir({ dir, strict = false, hashConcurrency = null } = {}) {
|
|
441
|
+
if (!dir) throw new Error("dir is required");
|
|
442
|
+
if (strict !== true && strict !== false) throw new TypeError("strict must be a boolean");
|
|
443
|
+
hashConcurrency = normalizeHashConcurrency(hashConcurrency);
|
|
444
|
+
|
|
445
|
+
const warnings = [];
|
|
446
|
+
if (!strict) {
|
|
447
|
+
const rawTrusted = String(process.env.SETTLD_TRUSTED_GOVERNANCE_ROOT_KEYS_JSON ?? "").trim();
|
|
448
|
+
if (!rawTrusted) warnings.push({ code: VERIFICATION_WARNING_CODE.TRUSTED_GOVERNANCE_ROOT_KEYS_MISSING_LENIENT, detail: { env: "SETTLD_TRUSTED_GOVERNANCE_ROOT_KEYS_JSON" } });
|
|
449
|
+
}
|
|
450
|
+
|
|
451
|
+
const settldPath = path.join(dir, "settld.json");
|
|
452
|
+
const manifestPath = path.join(dir, "manifest.json");
|
|
453
|
+
|
|
454
|
+
const header = await readJson(settldPath);
|
|
455
|
+
if (header?.type !== FINANCE_PACK_BUNDLE_TYPE_V1) {
|
|
456
|
+
return { ok: false, error: "unsupported bundle type", type: header?.type ?? null, warnings };
|
|
457
|
+
}
|
|
458
|
+
|
|
459
|
+
const manifestWithHash = await readJson(manifestPath);
|
|
460
|
+
if (manifestWithHash?.schemaVersion !== FINANCE_PACK_BUNDLE_MANIFEST_SCHEMA_V1) {
|
|
461
|
+
return { ok: false, error: "unsupported manifest schemaVersion", schemaVersion: manifestWithHash?.schemaVersion ?? null, warnings };
|
|
462
|
+
}
|
|
463
|
+
|
|
464
|
+
{
|
|
465
|
+
const pre = prevalidateManifestFileEntries({ bundleDir: dir, manifestFiles: manifestWithHash?.files });
|
|
466
|
+
if (!pre.ok) return { ...pre, warnings };
|
|
467
|
+
}
|
|
468
|
+
|
|
469
|
+
const expectedManifestHash = String(manifestWithHash?.manifestHash ?? "");
|
|
470
|
+
if (!expectedManifestHash) return { ok: false, error: "manifest missing manifestHash", warnings };
|
|
471
|
+
const manifestCore = stripManifestHash(manifestWithHash);
|
|
472
|
+
const actualManifestHash = sha256HexUtf8(canonicalJsonStringify(manifestCore));
|
|
473
|
+
if (actualManifestHash !== expectedManifestHash) {
|
|
474
|
+
return { ok: false, error: "manifestHash mismatch", expected: expectedManifestHash, actual: actualManifestHash, warnings };
|
|
475
|
+
}
|
|
476
|
+
|
|
477
|
+
// Strict profile: manifest must enumerate mandatory payload files (prevents "selective manifest" attacks).
|
|
478
|
+
{
|
|
479
|
+
const present = new Set();
|
|
480
|
+
for (const f of manifestWithHash.files ?? []) {
|
|
481
|
+
const name = typeof f?.name === "string" ? f.name : null;
|
|
482
|
+
if (!name) continue;
|
|
483
|
+
present.add(name);
|
|
484
|
+
}
|
|
485
|
+
const required = [
|
|
486
|
+
"settld.json",
|
|
487
|
+
"governance/policy.json",
|
|
488
|
+
"governance/revocations.json",
|
|
489
|
+
"month/manifest.json",
|
|
490
|
+
"month/keys/public_keys.json",
|
|
491
|
+
"finance/GLBatch.v1.json",
|
|
492
|
+
"finance/JournalCsv.v1.json",
|
|
493
|
+
"finance/JournalCsv.v1.csv",
|
|
494
|
+
"finance/reconcile.json"
|
|
495
|
+
];
|
|
496
|
+
const missing = required.filter((n) => !present.has(n));
|
|
497
|
+
if (strict && missing.length) return { ok: false, error: "manifest missing required files", missing, warnings };
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
// Verify every file hash listed in manifest.json (streaming, concurrency-limited).
|
|
501
|
+
{
|
|
502
|
+
const check = await verifyManifestFileHashes({ dir, manifestFiles: manifestWithHash.files, warnings, hashConcurrency });
|
|
503
|
+
if (!check.ok) return check;
|
|
504
|
+
}
|
|
505
|
+
|
|
506
|
+
// Governance policy: strict signer authorization contract.
|
|
507
|
+
// v1 exists for non-strict/legacy compatibility; strict requires v2 with governance-root signature.
|
|
508
|
+
let governancePolicy = null;
|
|
509
|
+
let revocationTimelineByKeyId = new Map();
|
|
510
|
+
let trustedGovernanceRoots = new Map();
|
|
511
|
+
let trustedTimeAuthorities = new Map();
|
|
512
|
+
try {
|
|
513
|
+
const policyJson = await readJson(path.join(dir, "governance", "policy.json"));
|
|
514
|
+
const schemaVersion = String(policyJson?.schemaVersion ?? "");
|
|
515
|
+
if (schemaVersion === GOVERNANCE_POLICY_SCHEMA_V2) {
|
|
516
|
+
const parsed = parseGovernancePolicyV2(policyJson);
|
|
517
|
+
if (!parsed.ok) {
|
|
518
|
+
if (strict) return { ok: false, error: "invalid governance/policy.json", detail: parsed };
|
|
519
|
+
} else {
|
|
520
|
+
governancePolicy = parsed.policy;
|
|
521
|
+
}
|
|
522
|
+
} else {
|
|
523
|
+
const parsed = parseGovernancePolicyV1(policyJson);
|
|
524
|
+
if (!parsed.ok) {
|
|
525
|
+
if (strict) return { ok: false, error: "invalid governance/policy.json", detail: parsed };
|
|
526
|
+
} else {
|
|
527
|
+
governancePolicy = parsed.policy;
|
|
528
|
+
}
|
|
529
|
+
}
|
|
530
|
+
} catch {
|
|
531
|
+
if (strict) return { ok: false, error: "missing governance/policy.json", warnings };
|
|
532
|
+
warnings.push({ code: VERIFICATION_WARNING_CODE.GOVERNANCE_POLICY_MISSING_LENIENT });
|
|
533
|
+
}
|
|
534
|
+
if (!strict && governancePolicy && String(governancePolicy.schemaVersion ?? "") !== GOVERNANCE_POLICY_SCHEMA_V2) {
|
|
535
|
+
warnings.push({
|
|
536
|
+
code: VERIFICATION_WARNING_CODE.GOVERNANCE_POLICY_V1_ACCEPTED_LENIENT,
|
|
537
|
+
detail: { schemaVersion: governancePolicy.schemaVersion ?? null }
|
|
538
|
+
});
|
|
539
|
+
}
|
|
540
|
+
|
|
541
|
+
if (strict) {
|
|
542
|
+
if (!governancePolicy) return { ok: false, error: "missing governance policy", warnings };
|
|
543
|
+
if (String(governancePolicy.schemaVersion ?? "") !== GOVERNANCE_POLICY_SCHEMA_V2) {
|
|
544
|
+
return { ok: false, error: "strict requires GovernancePolicy.v2", schemaVersion: governancePolicy.schemaVersion ?? null, warnings };
|
|
545
|
+
}
|
|
546
|
+
trustedGovernanceRoots = trustedGovernanceRootKeysFromEnv();
|
|
547
|
+
if (trustedGovernanceRoots.size === 0) {
|
|
548
|
+
return { ok: false, error: "strict requires trusted governance root keys", env: "SETTLD_TRUSTED_GOVERNANCE_ROOT_KEYS_JSON", warnings };
|
|
549
|
+
}
|
|
550
|
+
const sigOk = verifyGovernancePolicyV2Signature({ policy: governancePolicy, trustedGovernanceRootPublicKeyByKeyId: trustedGovernanceRoots });
|
|
551
|
+
if (!sigOk.ok) return { ok: false, error: "governance policy signature invalid", detail: sigOk, warnings };
|
|
552
|
+
|
|
553
|
+
const refPath = String(governancePolicy?.revocationList?.path ?? "");
|
|
554
|
+
if (!refPath || !refPath.startsWith("governance/")) {
|
|
555
|
+
return { ok: false, error: "governance policy revocationList.path invalid", path: governancePolicy?.revocationList?.path ?? null, warnings };
|
|
556
|
+
}
|
|
557
|
+
const revJson = await readJson(path.join(dir, refPath));
|
|
558
|
+
const parsedList = parseRevocationListV1(revJson);
|
|
559
|
+
if (!parsedList.ok) return { ok: false, error: "invalid governance revocation list", detail: parsedList, warnings };
|
|
560
|
+
const listSigOk = verifyRevocationListV1Signature({ list: parsedList.list, trustedGovernanceRootPublicKeyByKeyId: trustedGovernanceRoots });
|
|
561
|
+
if (!listSigOk.ok) return { ok: false, error: "revocation list signature invalid", detail: listSigOk, warnings };
|
|
562
|
+
const expectedSha = String(governancePolicy?.revocationList?.sha256 ?? "");
|
|
563
|
+
if (!expectedSha || listSigOk.listHash !== expectedSha) {
|
|
564
|
+
return { ok: false, error: "revocation list hash mismatch", expected: expectedSha || null, actual: listSigOk.listHash ?? null, warnings };
|
|
565
|
+
}
|
|
566
|
+
revocationTimelineByKeyId = deriveKeyTimelineFromRevocationList(parsedList.list);
|
|
567
|
+
trustedTimeAuthorities = trustedTimeAuthorityKeysFromEnv();
|
|
568
|
+
}
|
|
569
|
+
|
|
570
|
+
// Anchor checks (best-effort, but deterministic).
|
|
571
|
+
const inputs = header?.inputs ?? {};
|
|
572
|
+
|
|
573
|
+
// MonthProofBundle anchor and strict verification (if requested).
|
|
574
|
+
const monthDir = path.join(dir, "month");
|
|
575
|
+
let monthStrict = null;
|
|
576
|
+
if (strict) {
|
|
577
|
+
monthStrict = await verifyMonthProofBundleDir({ dir: monthDir, strict: true, hashConcurrency });
|
|
578
|
+
if (!monthStrict.ok) return { ok: false, error: "month proof strict verification failed", detail: monthStrict, warnings };
|
|
579
|
+
}
|
|
580
|
+
|
|
581
|
+
// MonthProofBundle anchor: compare against the nested month/manifest.json manifestHash.
|
|
582
|
+
const monthManifest = await readJson(path.join(monthDir, "manifest.json"));
|
|
583
|
+
const monthManifestHash = String(monthManifest?.manifestHash ?? "");
|
|
584
|
+
if (typeof inputs?.monthProofBundleHash === "string" && inputs.monthProofBundleHash !== monthManifestHash) {
|
|
585
|
+
return { ok: false, error: "monthProofBundleHash mismatch", expected: inputs.monthProofBundleHash, actual: monthManifestHash, warnings };
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
// FinancePack head attestation (strict requires it).
|
|
589
|
+
let headAttestation = null;
|
|
590
|
+
try {
|
|
591
|
+
headAttestation = await readJson(path.join(dir, "attestation", "bundle_head_attestation.json"));
|
|
592
|
+
} catch {
|
|
593
|
+
headAttestation = null;
|
|
594
|
+
}
|
|
595
|
+
if (strict && !headAttestation) return { ok: false, error: "missing attestation/bundle_head_attestation.json" };
|
|
596
|
+
if (!strict && !headAttestation) warnings.push({ code: VERIFICATION_WARNING_CODE.BUNDLE_HEAD_ATTESTATION_MISSING_LENIENT });
|
|
597
|
+
|
|
598
|
+
// Read month keys (needed for finance pack attestation signature + report signature).
|
|
599
|
+
let monthPublicKeys = null;
|
|
600
|
+
try {
|
|
601
|
+
const keysJson = await readJson(path.join(monthDir, "keys", "public_keys.json"));
|
|
602
|
+
monthPublicKeys = parsePublicKeysV1(keysJson);
|
|
603
|
+
} catch {
|
|
604
|
+
monthPublicKeys = null;
|
|
605
|
+
}
|
|
606
|
+
|
|
607
|
+
if (strict && !(monthPublicKeys?.ok)) {
|
|
608
|
+
return { ok: false, error: "missing month keys/public_keys.json (PublicKeys.v1)", warnings };
|
|
609
|
+
}
|
|
610
|
+
|
|
611
|
+
// Derive governed server key lifecycles from MonthProof global governance events (MonthProof strict already validated them).
|
|
612
|
+
if (monthPublicKeys?.ok && strict) {
|
|
613
|
+
const raw = await fs.readFile(path.join(monthDir, "governance", "global", "events", "events.jsonl"), "utf8");
|
|
614
|
+
const govEvents = parseJsonl(raw);
|
|
615
|
+
const derived = deriveServerKeyTimelineFromGovernanceEvents(govEvents);
|
|
616
|
+
monthPublicKeys.keyMetaByKeyId = applyDerivedServerTimeline({ keyMetaByKeyId: monthPublicKeys.keyMetaByKeyId, derived });
|
|
617
|
+
}
|
|
618
|
+
|
|
619
|
+
let headAttestationVerify = null;
|
|
620
|
+
if (headAttestation) {
|
|
621
|
+
const monthAttestationHash = typeof monthStrict?.headAttestation?.attestationHash === "string" ? monthStrict.headAttestation.attestationHash : null;
|
|
622
|
+
headAttestationVerify = verifyBundleHeadAttestationV1({
|
|
623
|
+
attestation: headAttestation,
|
|
624
|
+
expectedManifestHash,
|
|
625
|
+
expectedTenantId: header?.tenantId ?? null,
|
|
626
|
+
expectedPeriod: header?.period ?? null,
|
|
627
|
+
monthManifestHash,
|
|
628
|
+
monthAttestationHash,
|
|
629
|
+
governancePolicy,
|
|
630
|
+
revocationTimelineByKeyId,
|
|
631
|
+
trustedTimeAuthorities,
|
|
632
|
+
publicKeyByKeyId: monthPublicKeys.publicKeyByKeyId,
|
|
633
|
+
keyMetaByKeyId: monthPublicKeys.keyMetaByKeyId,
|
|
634
|
+
strict
|
|
635
|
+
});
|
|
636
|
+
if (!headAttestationVerify.ok) return { ok: false, error: "bundle head attestation invalid", detail: headAttestationVerify, warnings };
|
|
637
|
+
}
|
|
638
|
+
|
|
639
|
+
// VerificationReport.v1 (strict requires it, signed).
|
|
640
|
+
let verificationReport = null;
|
|
641
|
+
try {
|
|
642
|
+
verificationReport = await readJson(path.join(dir, "verify", "verification_report.json"));
|
|
643
|
+
} catch {
|
|
644
|
+
verificationReport = null;
|
|
645
|
+
}
|
|
646
|
+
if (strict && !verificationReport) return { ok: false, error: "missing verify/verification_report.json" };
|
|
647
|
+
if (!strict && !verificationReport) warnings.push({ code: VERIFICATION_WARNING_CODE.VERIFICATION_REPORT_MISSING_LENIENT });
|
|
648
|
+
|
|
649
|
+
let verificationReportVerify = null;
|
|
650
|
+
if (verificationReport) {
|
|
651
|
+
verificationReportVerify = verifyVerificationReportV1({
|
|
652
|
+
report: verificationReport,
|
|
653
|
+
expectedManifestHash,
|
|
654
|
+
monthPublicKeys: monthPublicKeys?.ok ? monthPublicKeys : null,
|
|
655
|
+
governancePolicy,
|
|
656
|
+
revocationTimelineByKeyId,
|
|
657
|
+
trustedTimeAuthorities,
|
|
658
|
+
strict
|
|
659
|
+
});
|
|
660
|
+
if (!verificationReportVerify.ok) return { ok: false, error: "verification report invalid", detail: verificationReportVerify, warnings };
|
|
661
|
+
|
|
662
|
+
// Surface producer-time warnings (from the signed VerificationReport) as top-level warnings so CI can gate on them.
|
|
663
|
+
// These warnings are already schema-validated by verifyVerificationReportV1().
|
|
664
|
+
if (Array.isArray(verificationReport.warnings) && verificationReport.warnings.length) {
|
|
665
|
+
for (const w of verificationReport.warnings) {
|
|
666
|
+
if (!w || typeof w !== "object" || Array.isArray(w)) continue;
|
|
667
|
+
const code = typeof w.code === "string" && w.code.trim() ? w.code : null;
|
|
668
|
+
if (!code) continue;
|
|
669
|
+
warnings.push({ code, detail: { source: "verification_report" } });
|
|
670
|
+
}
|
|
671
|
+
}
|
|
672
|
+
|
|
673
|
+
if (strict) {
|
|
674
|
+
const declaredAttHash = verificationReport?.bundleHeadAttestation?.attestationHash ?? null;
|
|
675
|
+
const expectedAttHash = headAttestationVerify?.attestationHash ?? null;
|
|
676
|
+
if (typeof expectedAttHash === "string" && expectedAttHash.trim() && String(declaredAttHash ?? "") !== expectedAttHash) {
|
|
677
|
+
return { ok: false, error: "verification report bundleHeadAttestation.attestationHash mismatch", expected: expectedAttHash, actual: declaredAttHash ?? null };
|
|
678
|
+
}
|
|
679
|
+
}
|
|
680
|
+
}
|
|
681
|
+
|
|
682
|
+
// GLBatch artifact hash and version checks.
|
|
683
|
+
const glBatch = await readJson(path.join(dir, "finance", "GLBatch.v1.json"));
|
|
684
|
+
const glHash = verifyArtifactTypeAndHash({ artifact: glBatch, expectedType: "GLBatch.v1" });
|
|
685
|
+
if (!glHash.ok) return { ok: false, error: `GLBatch: ${glHash.error}`, detail: glHash, warnings };
|
|
686
|
+
if (typeof inputs?.glBatchHash === "string" && inputs.glBatchHash !== glBatch.artifactHash) {
|
|
687
|
+
return { ok: false, error: "glBatchHash mismatch", expected: inputs.glBatchHash, actual: glBatch.artifactHash, warnings };
|
|
688
|
+
}
|
|
689
|
+
|
|
690
|
+
// JournalCsv artifact checks + csv bytes hash.
|
|
691
|
+
const journalCsv = await readJson(path.join(dir, "finance", "JournalCsv.v1.json"));
|
|
692
|
+
const csvSha = await hashFile(path.join(dir, "finance", "JournalCsv.v1.csv"), { algo: "sha256" });
|
|
693
|
+
const csvHash = verifyArtifactTypeAndHash({ artifact: journalCsv, expectedType: "JournalCsv.v1" });
|
|
694
|
+
if (!csvHash.ok) return { ok: false, error: `JournalCsv: ${csvHash.error}`, detail: csvHash, warnings };
|
|
695
|
+
if (typeof journalCsv?.csvSha256 === "string" && journalCsv.csvSha256 !== csvSha) {
|
|
696
|
+
return { ok: false, error: "journalCsv.csvSha256 mismatch", expected: journalCsv.csvSha256, actual: csvSha, warnings };
|
|
697
|
+
}
|
|
698
|
+
if (typeof inputs?.journalCsvHash === "string" && inputs.journalCsvHash !== csvSha) {
|
|
699
|
+
return { ok: false, error: "journalCsvHash mismatch", expected: inputs.journalCsvHash, actual: csvSha, warnings };
|
|
700
|
+
}
|
|
701
|
+
if (typeof inputs?.journalCsvArtifactHash === "string" && inputs.journalCsvArtifactHash !== journalCsv.artifactHash) {
|
|
702
|
+
return { ok: false, error: "journalCsvArtifactHash mismatch", expected: inputs.journalCsvArtifactHash, actual: journalCsv.artifactHash, warnings };
|
|
703
|
+
}
|
|
704
|
+
if (typeof inputs?.financeAccountMapHash === "string" && inputs.financeAccountMapHash !== journalCsv.accountMapHash) {
|
|
705
|
+
return { ok: false, error: "financeAccountMapHash mismatch", expected: inputs.financeAccountMapHash, actual: journalCsv.accountMapHash, warnings };
|
|
706
|
+
}
|
|
707
|
+
|
|
708
|
+
// Reconcile: compare stored reconcile.json with recomputed result.
|
|
709
|
+
const reconcileOnDisk = await readJson(path.join(dir, "finance", "reconcile.json"));
|
|
710
|
+
const partyStatementsDir = path.join(dir, "month", "artifacts", "PartyStatement.v1");
|
|
711
|
+
const partyStatements = [];
|
|
712
|
+
try {
|
|
713
|
+
const psEntries = (await fs.readdir(partyStatementsDir, { withFileTypes: true }))
|
|
714
|
+
.filter((e) => e.isFile() && e.name.endsWith(".json"))
|
|
715
|
+
.map((e) => path.join(partyStatementsDir, e.name))
|
|
716
|
+
.sort();
|
|
717
|
+
for (const fp of psEntries) {
|
|
718
|
+
// eslint-disable-next-line no-await-in-loop
|
|
719
|
+
partyStatements.push(await readJson(fp));
|
|
720
|
+
}
|
|
721
|
+
} catch {
|
|
722
|
+
// If party statements aren't present, skip recompute (still have manifest + hashes).
|
|
723
|
+
}
|
|
724
|
+
|
|
725
|
+
if (partyStatements.length) {
|
|
726
|
+
const reconcileComputed = reconcileGlBatchAgainstPartyStatements({ glBatch, partyStatements });
|
|
727
|
+
if (!reconcileComputed.ok) return { ok: false, error: `reconcile failed: ${reconcileComputed.error}`, detail: reconcileComputed, warnings };
|
|
728
|
+
if (canonicalJsonStringify(reconcileComputed) !== canonicalJsonStringify(reconcileOnDisk)) {
|
|
729
|
+
return { ok: false, error: "reconcile.json mismatch", expected: reconcileComputed, actual: reconcileOnDisk, warnings };
|
|
730
|
+
}
|
|
731
|
+
}
|
|
732
|
+
|
|
733
|
+
const reconcileSha = await hashFile(path.join(dir, "finance", "reconcile.json"), { algo: "sha256" });
|
|
734
|
+
if (typeof inputs?.reconcileReportHash === "string" && inputs.reconcileReportHash !== reconcileSha) {
|
|
735
|
+
return { ok: false, error: "reconcileReportHash mismatch", expected: inputs.reconcileReportHash, actual: reconcileSha, warnings };
|
|
736
|
+
}
|
|
737
|
+
|
|
738
|
+
return {
|
|
739
|
+
ok: true,
|
|
740
|
+
strict,
|
|
741
|
+
warnings,
|
|
742
|
+
monthStrict: monthStrict?.ok ? monthStrict : null,
|
|
743
|
+
headAttestation: headAttestationVerify?.ok ? headAttestationVerify : null,
|
|
744
|
+
verificationReport: verificationReportVerify?.ok ? verificationReportVerify : null,
|
|
745
|
+
type: header.type,
|
|
746
|
+
period: header.period,
|
|
747
|
+
tenantId: header.tenantId,
|
|
748
|
+
manifestHash: expectedManifestHash
|
|
749
|
+
};
|
|
750
|
+
}
|