Repository navigation
feat(spec)!: let a sidecar outrank an unreadable footer, separate attestation_status - #74
Merged
Merged
Conversation
…estation_status §3.1: when the last 16 bytes carry the VCAP magic but are no usable footer (CRC fails, major != 1, size describes no trailer) and a sidecar is present, the sidecar is also judged over the file without the unreadable trailer: the declared free box when it fits and its header matches, else the 16-byte footer. It decides only when its outcome ranks strictly higher, with the new label "trailer unreadable" and proof_source sidecar. §6.2: attestation_status is signed over "vcap/1.0/attestation-status" || core_hash || JCS(entries) || uint64 BE fetched_at, closing the known inconsistency. Corpus 7.0.0 -> 8.0.0: 25 attestation_status vectors re-signed (verdicts unchanged), vector 72 moves to authentic, vectors 188-193 added. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
Two owner decisions (5 October 2026). Corpus 7.0.0 → 8.0.0, major: 25 vectors re-signed and vector 72 changes verdict.
A. A sidecar that does better than an unreadable footer (§3.1)
Before: if the last 16 bytes started with
VCAPand the footer could not be used, that footer decided the verdict no matter what sidecar was present:So anyone could append such a footer to a trailer-stripped genuine file and make it read broken next to its genuine sidecar. #72 left this open.
Verifier algorithm
len(F) ≥ 16, the last 16 bytes start with"VCAP", they are not a valid footer with a matching CRC, and a sidecar is present.V0, the verdict as before (steps 1–5 unchanged).n=payload_len(uint32 BE atlen(F) − 8, read at its v1 position whatever the major). LetT = 8 + n + 16, summed without overflow.T ≤ len(F)andF[len(F)−T : +4] == T(uint32 BE) andF[len(F)−T+4 : +4] == "free", thenF' = F[0 : len(F) − T]. OtherwiseF' = F[0 : len(F) − 16].F'the way step 4 judges a sidecar: canonical bytes = all ofF'(§4.1 step 2). Nothing further is stripped, even ifF'ends in another trailer. The result isV1, with labelstrailer unreadable(+manifest copy differsif the active manifest ofF'differs from the sidecar), andproof_source: sidecar.V1ifrank(V1) > rank(V0), elseV0.Why this span:
media.hashor segment hashes to match what remains, so a declared span cannot upgrade forged bytes. A wrong span only costs the sidecar its outcome.freebox header is required, so the removed bytes are either a box every reader skips or 16 bytes that are not a box. Vector 191 pins this.Nested behaviour is unchanged: one trailer removed, no recursion (vector 193). A C2PA store is not a sidecar here (126 unchanged). Existing labels are unchanged.
B.
attestation_statusdomain separator (§6.2)Same style as
vcap/1.0/sth,/status,/integrity,/location,/seg. Reference:attestationStatusMessage(tools/src/registry.ts). Also updated: the §6.2 table, the inconsistency note, the schemasigdescription, and the threat model (§5.3 Cross-message signature).Vectors
attestation_statusA verifier that predates 8.0.0, measured with the 7.0.0 reference verifier:
Docs
Updated: CHANGELOG (breaking, includes the pre-8.0.0 behaviour), §3.1/§4.1/§8/§11, the threat model (the open item is closed), the c2pa-interop table, vectors README, CONFORMANCE, VERSION, MANIFEST and the conformance report.
Gates (local, Node 22)
All passed:
npm run generatetwice: no diff on the second run🤖 Generated with Claude Code