Skip to main content

Module trust

Module trust 

Source
Expand description

Trust roots for provenance attestation, and the host-side verifier that consumes them (SPEC.md §6.5, F8–F9; ADR 0016).

ADR 0010 specifies the bytes a provider signs and deliberately stops there, so a provider holding keys in an HSM signs a public 32-byte commitment with its own backend. That leaves the question on the host’s side of the wire: given a ProvenanceAttestation and a frame, where does the public key come from?

The answer here is the only one that needs no organization behind it: the operator is the trust root. A TrustStore maps a provider_id to the keys that provider may sign under, and a key is in it because a person put it there — from the same material, in the same act, as the provider’s own configuration and its consent grant. This is how ssh learns a host key and how minisign learns a signer. A registry, a well-known endpoint or a transparency log would all work better and all require a party both sides already trust; GOVERNANCE.md’s consent boundary rules that out for a host, and the attestation stays portable enough for one to be built over this.

§F9 is the load-bearing rule

An attestation this host cannot verify degrades its frame to unattested. It never disqualifies it. A host that dropped such frames would hand any peer a denial-of-service primitive — attach a malformed attestation, watch the evidence vanish — so every path in this module ends in an AttestationState and none of them ends in a dropped frame. Verification adds a fact to the audit; it never subtracts evidence and never reranks.

§Attacker-controlled work is bounded before any cryptography runs

Every field of an attestation arrives from the provider, so this module checks the cheap structural facts first and only then hashes or verifies: an oversized signature is rejected on its length rather than hex-decoded, an attestation naming an unknown key_id never reaches the signature check at all, and at most one attestation is verified per frame. The frame count is already bounded by the max_frames audit that runs before this (Host::query_all), so the total work is linear in a quantity the host already agreed to accept.

Structs§

AttestationLedger
Every frame’s attestation state from one fan-out, keyed by identity — the join the composer reads so an AuditEntry can say whether the evidence it quotes was signed.
FrameAttestationOutcome
One frame’s attestation outcome, keyed by the frame’s stable identity so it joins the composition audit without a positional assumption.
TrustStore
The keys a host trusts, per provider — the local answer to “who may sign evidence I will treat as attested?” (ADR 0016).
TrustedKey
An Ed25519 public key a host trusts for one provider.

Enums§

AttestationState
What a host found when it checked one frame’s attestation (ADR 0016 §4).