Preserve Kit layer integrity checks after opt-in validation change #227
Notifications
Due Date
No due date set.
Reference: sam/archie#227
Reference in new issue
Block a user
sandbox-kit-spec m.7 makes layer validation opt-in through fetch.Options.LayerValidator; nil skips layer reads and checks. Audit the migrated kitrun resolution/assembly path and explicitly retain digest verification, safe extraction, resource bounds, and collision checks wherever Archie consumes assembled layers. Trace the actual image consumed by the container so validation applies to that artifact. Upstream default validator is fetch.DefaultLayerValidator; use it rather than adding a checker.
Acceptance criteria
Document the actual assembly-to-container artifact path in issue evidence; malformed digests and unsafe or colliding layer entries are refused before launch on applicable paths; valid Kits still launch; security regression coverage and task check pass.
Notes
Investigation complete in
be31522e. The old fetch.Client.Assemble only merged declarations; it never assembled or extracted image layers. Its replacement Fetch.Resolve reads bounded, digest-verified registry metadata (upstream fetchManifest/readVerified). Runtime config.ValidateProfiles requires digest-pinned images. kitrun.imageConfig -> Pool.EnsureImage/ImageInspect and AcquireKit -> StartKit use that same published image reference, with pulling and layer extraction owned by Docker. No fetch.Options, package-level fetch.Assemble, LayerLoader, or daemon raw-layer extraction path is introduced, so opt-in DefaultLayerValidator and cross-Kit assembly collision checks are not applicable here. Kept the single Docker image boundary instead of introducing a redundant assembler. TestKitRuntimeDiscovery launches a real Docker container and checks safe runtime file staging; task check passed. No claim is made that this test injects malformed Docker layers.Close reason
API migration or audit completed in be31522e; task check, Docker acceptance and focused race tests passed.
Imported from beads
archie-core-egkf.17· GitHub #1515 · type task · priority P1 · created 2026-10-09 · closed 2026-10-09