Repository navigation
Add containerd patch to handle dmverity referrers - #99
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The security-critical referrer discovery and validation pipeline lacks focused automated tests.
1 open finding
What changed in this PR
Adds opt-in signed dm-verity referrer support to containerd’s EROFS snapshotter and CRI integration.
Changes:
- Discovers, caches, validates, and materializes signed dm-verity artifacts.
- Separates signed and unsigned snapshot identities and supports offline reuse.
- Enables the patch in the containerd2 RPM.
| File | Description |
|---|---|
acl/SPECS/containerd2/erofs-signed-dmverity.patch |
Implements signed referrer handling across transfer, CRI, unpack, EROFS, and dm-verity paths. |
acl/SPECS/containerd2/containerd2.spec |
Applies the patch and increments the package release. |
🧠 Review effort: Balanced
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
|
Adding a comment from the config toggle PR as a limitation of this change: "AgentBaker skips existing images by name and otherwise imports the pause image using the default overlayfs snapshotter. If it is only prepared for overlayfs, switching to EROFS triggers another pull. On network-isolated nodes whose bootstrap registry requires authentication, that runtime pull cannot authenticate. Pods then cannot start, even though the pause image is already cached. Azure/AgentBaker#9761 updates VHD precaching but does not change this bootstrap logic." |
249201b to
5805876
Compare
There was a problem hiding this comment.
🟡 Changes recommended
Test-compilation failures, image-selection and cache regressions, and unbounded signature reads remain unresolved.
6 open issues
Use the requested manifest for signed image validation · New Bound signature reads to prevent memory exhaustion · New Update EROFS tests for new helper signatures · New Preserve unambiguous ID-based cached image resolution · New Refresh cached snapshotters for existing image references · New Add unit tests for referrer discovery and validation paths
Review effort: Balanced
There was a problem hiding this comment.
🟡 Changes recommended
Unsigned image-ID resolution can regress, and security-sensitive snapshot isolation and mount guards lack targeted regression tests.
5 open issues
Add regression tests for snapshot isolation and cache validation · New Allow resolution of unsigned manifests sharing a config · New Add coverage for signed-parent protection in merged fsmeta · New Refresh cached snapshotters for existing image references Add unit tests for referrer discovery and validation paths
4 resolved since last review
Review effort: Balanced
…/signed snapshot chain - preserve signed observations when metadata-only traversal filters non-target platform layers
|
suggestion (non-blocking): Please retain the focused signed-referrer and snapshot-cache regression tests, possibly in a separate test-only patch. Removing them means the RPM's |


Summary
Patch containerd to be able to discover dmverity OCI referrers if new config option
enable_dmverity_referrersis present. This patch represents changes to support this in the CRI, transfer service, unpacker, differ, snapshotter, and mount paths.Tests have intentionally been stripped from this patch to reduce its size.
Additions
application/vnd.containerd.erofs.dmverity.v1for an image manifest and stores its per-layer EROFS metadata, Merkle tree, and detached PKCS#7 root-hash signature in the content store.enable_dmverity_referrersindicates the snapshotter is capable of referrer fetching. The snapshotter will materialize the published artifacts alongside the original layer tar data.Limitations and Prerequisites
enable_dmverity_referrersenabled in the config, a compatible dm-verity mode, and the required kernel support.PR that will invoke this behavior when IPE is enabled: #98
Change Log
Type of Change
Does this affect the image build?
Associated Issues
Test Methodology
Test methods:
Merge Checklist
All applicable boxes should be checked before merging