jcp: JCR-1 receipts bind their payload — jcp/2 + version dispatch (SPEC §8, C23) #23
Loading…
Reference in a new issue
No description provided.
Delete branch "jcp/receipt-payload-hash"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
A
jcp/1receipt proved a decision happened — over this grant, for this action, at this cost — but not what it was over. Two decisions differing only in payload sealed to identical bytes, so a tool-call receipt never committed its arguments and a payload substitution was undetectable in the audit.This adds
payload_hashto the signed core and bumps the profile tojcp/2.The bump is honest, not silent
Until now the
jcp_receipttag was written but never read — decorative. It is now load-bearing:verify/verify_chainedread the profile out of the signed core and recompute the preimage under that profile. So receipts sealed asjcp/1keep verifying, and an unrecognised tag is refused rather than assumed.jcp/1is no longer minted.Migration proven with real bytes
The allow receipt published in
conformance/v1/vectors.jsonbefore this change is embedded in a test and must still verify — not a reconstruction, the actual bytes. Both v1 receipts are preserved asconformance/v1/legacy_jcp1.jsonso cross-language verifiers can prove they honour the dispatch.Scope — verified, not assumed
JCR-1 is a family of sibling profiles sharing the envelope (canonical det-CBOR + COSE_Sign1/EdDSA) and vocabulary, each signing its own core:
jouleclaw-jcr1is an independent implementation but signs its own receipt kinds (coding/stream windows, ui output) — zerogrant_id/verdict.sense/map/sandboxvectors carry their own cores;maptags its own"map/1".So this changes one profile among siblings and does not touch theirs. SPEC §8 now states that explicitly, replacing a sentence that implied a single family-wide core.
Also
_chainedand_loggedboth funnel throughto_jcr1_wire.ReceiptCore.payload_hash: Option<String>—Someon jcp/2,Noneon legacy, so callers can tell a payload-bound receipt from one that isn't.jcp/1still verifies.40 suites green, clippy clean, all conformance checks pass.
dcharlot referenced this pull request2026-11-06 13:54:17 -05:00