Expand description
Manifest schema, trust model, and fallback chain.
This module implements:
Manifest— the top-level manifest structure with components and metadataManifestOverlay— a remote overlay that merges onto the baseline- Trust verification — signature, schema version anti-rollback, expiry
- Three-tier fallback chain — fresh remote → cached remote → bundled baseline
§Trust Model
Every remote manifest must pass three trust checks before use:
- Signature verification — HMAC-SHA256 against a known key
- Schema version — must be ≥
MIN_SCHEMA_VERSION(anti-rollback) - Expiry — if
expires_atis set, must not be in the past
§Fallback Chain
fresh remote (if trust checks pass)
↓ fetch failure
cached remote (if valid cache exists)
↓ no cache
bundled baseline (always available, compiled into binary)Structs§
- Manifest
- The top-level manifest structure.
- Manifest
Component - A single component entry within a manifest.
- Manifest
Overlay - A remote overlay that merges onto a baseline manifest.
- Resolved
Manifest - Result of manifest fallback resolution.
Enums§
- Manifest
Source - Source of the manifest after fallback resolution.
- Manifest
Trust Error - Errors that can occur during manifest trust verification.
Constants§
- CURRENT_
SCHEMA_ VERSION - Current schema version produced/consumed by this binary.
- MIN_
SCHEMA_ VERSION - Minimum supported schema version. Manifests with a lower version are rejected.
Traits§
- Manifest
Fetcher - Trait for fetching and caching manifests. Implementations provide the actual remote fetch and cache read/write logic.
Functions§
- create_
signed_ manifest - Create a test manifest with a valid signature.
- resolve_
manifest - Resolve a manifest using the three-tier fallback chain.