Expand description
Accreditation evidence library (S42/S43/S44, ADR-0032).
This crate turns the hand-authored control-mapping catalog
(contracts/controls/cellos-800-53-rev5-mapping.json) into machine-checked,
deterministically-emitted accreditation evidence. It does three things:
- Load + lint (S43).
load_catalogparses the catalog andlint_catalogasserts every entry validates against the control-mapping schema, that everycodeSeams/provingTestspath resolves on disk, thatstatus: implementedentries carry non-empty proving event types and tests, and that alinux-nftables+implementedentry carries adegradedBindingNote. - Emit (S44).
emit_oscalproduces an OSCAL-style component-definition + SSP fragment (EvidencePackage) where every implemented requirement carries machine-embedded remarks that this is a candidate, not an assessor-verified satisfaction. SC-13/IA-7 carry an explicit “crypto module NOT CMVP-validated” remark;linux-nftablesentries carry a platform-scope remark.
§Honesty invariants
The catalog is candidate evidence an operator hands to an assessor, not
a self-attestation of satisfaction (mirrors how a cortex receipt is a
candidate, never a direct admission). The emitter therefore stamps every
implemented requirement with candidate, not assessor-verified and refuses
to silently upgrade algorithm-present-not-validated (SC-13/IA-7) into a
validated claim.
§Determinism
emit_oscal is a pure function of the catalog bytes: entries are emitted
in catalog order and every map is a BTreeMap/ordered Vec, so two emit
runs are byte-identical. This is asserted by the crate tests.
Re-exports§
pub use rollup::rollup;pub use rollup::ControlCoverage;pub use rollup::RollupReport;pub use sign::sign_evidence_package;pub use sign::verify_evidence_package;pub use sign::EVIDENCE_PACKAGE_TYPE;
Modules§
Structs§
- Component
- One component (the CellOS substrate) carrying control implementations.
- Component
Definition - OSCAL-style component-definition fragment.
- Control
Implementation - One control implementation entry (component-definition side).
- Control
Mapping Entry - One control-mapping catalog entry. Field shape mirrors
control-mapping-v1.schema.json;#[serde(rename_all = "camelCase")]keeps the on-disk JSON keys identical to the schema. - Evidence
Package - The full deterministic evidence package: a component-definition and an
SSP fragment. Serialized with
serde_jsonin catalog order. - Implemented
Requirement - One implemented-requirement (SSP side).
- Metadata
- Metadata block shared by both fragments.
- SspFragment
- OSCAL-style SSP fragment.
Enums§
- Evidence
Error - Errors raised while loading or linting the catalog.
- Schema
Error - Schema load / compile errors.
Constants§
- CANDIDATE_
REMARK - Machine-embedded remark stamped on every emitted implemented requirement.
- CATALOG_
RELPATH - Repo-relative path to the canonical control-mapping catalog (S42).
- CRYPTO_
NOT_ VALIDATED_ REMARK - Machine-embedded remark for SC-13/IA-7 (algorithm-present-not-validated).
- SCHEMA_
RELPATH - Repo-relative path to the control-mapping JSON Schema (S41).
Functions§
- control_
mapping_ schema_ json - Read the control-mapping schema JSON from disk under
root. - emit_
oscal - Deterministically emit the OSCAL-style evidence package from the catalog
(S44). Pure function of
entries— emits in catalog order with ordered maps, so two runs over the same catalog are byte-identical. - emit_
oscal_ bytes - Serialize an
EvidencePackageto deterministic pretty JSON bytes. - lint_
catalog - Lint the catalog (S43).
- load_
catalog - Load and parse the control-mapping catalog under
root. - load_
catalog_ values - Load the raw catalog JSON values (schema-validated against the exact on-disk shape, not the deserialized struct). Used by the linter so that schema violations surface as schema errors rather than parse errors.
- repo_
root - Resolve the repo root from this crate’s manifest dir
(
<root>/crates/cellos-evidence). - validate_
entry - Validate a single entry value against the control-mapping schema under
root. Convenience wrapper that compiles a fresh validator.