feat(attest): pluggable attester seam with a deterministic sample implementation - #9220
Merged
Conversation
Deploying with
|
| Status | Name | Latest Commit | Preview URL | Updated (UTC) |
|---|---|---|---|---|
| ✅ Deployment successful! View logs |
loopover-ui | 70180d9 | Commit Preview URL Branch Preview URL |
Jul 27 2026, 07:24 AM |
JSONbored
force-pushed
the
feat/attester-seam
branch
from
July 27, 2026 07:22
c401ae5 to
70180d9
Compare
Contributor
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
… classification (#9211)
❌ 4 Tests Failed:
View the top 3 failed test(s) by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
Merged
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
The first slice of #9211: the pluggable boundary between collecting an attestation report and assembling the evidence envelope — so the attested-evaluation epic (#8534) can be built and CI-tested before any SEV-SNP-capable hardware exists.
Confidential Containers ships a no-TEE sample-attester path for exactly this reason. Mirroring it here means real hardware arrives as a config change (swap the
Attesterimplementation) rather than as new code on the critical path — which is what turns the current blocker into "hardware-blocked, not code-blocked".What lands:
Attester— the swappable interface (kind+ asynccollect), async because every real implementation performs IO.createSampleAttester()— deterministic and hardware-free: every field is derived from the request by SHA-256, so the same request yields byte-identical output and an attested-run E2E can assert exact bytes rather than "something was produced".assembleAttestationEnvelope()— computesreportDatafrom the binding itself rather than trusting a caller- or attester-supplied value, so the envelope's commitment and the bytes the attester signed over cannot drift apart. Returns{ ok: false }(never throws) when collection fails or the result doesn't validate, so a runner can recordattestation_failedinstead of crashing a completed evaluation.SAMPLE_ATTESTATION_MAGIC/isSampleAttestationReport()— a sample-attested envelope stays identifiable as a dev artifact.Safety posture (the point of the magic prefix): a sample envelope must never be presentable as real evidence. Two independent things stop that — the report carries the magic as its leading plaintext bytes so the verifier (#9212) can name it precisely, and a sample report has no AMD signature chain so cryptographic verification fails regardless. The magic is the honest error message; the missing chain is the actual guarantee.
Pure and infrastructure-free, matching the module family's contract: no IO, no randomness, no wall-clock reads. A real SEV-SNP attester talks to
/dev/sev-guestor a CoCo attestation agent and therefore lives in the IO layer that supplies it — that's the follow-up slice, along with the runner and envelope persistence.Part of #9211 · epic #8534
Validation
npx vitest run test/unit/attester-engine.test.ts— 13/13 passteeTechnology ?? "sev-snp"fallback both ways, all fourisSampleAttestationReportrejection paths (non-string, empty, malformed, valid-but-not-sample), invalid-collection, and both theErrorand non-Errorthrow arms.npm run test --workspace @loopover/engine— 737/737 (includes the 3 new barrel tests)Safety
node:cryptoonly, matching the sibling modules.