PROTOCOL RECORD
Canonical messages
ENZAN-CANONICAL-JSON-v1 serialization requirements.
Document status
- Status
- Implemented locally
IMPLEMENTED_LOCALLY - Public availability
- Not publicly deployed
NOT_PUBLICLY_AVAILABLE - Invokable
- No
- Public network endpoint available
- No
- Document kind
NORMATIVE- Protocol references
ENZAN-CANONICAL-JSON-v1
- Source revision
8a406488530dc73987b7e7c7534cd9a9d437b718- Last substantive review
- Evidence scopes
- Repository implementation and normative local verification vectors.
- Limitations
- This is repository-grounded local evidence only; no public endpoint or ordinary external invocation is available.
- This is a concise public description of the implemented local profile, not a substitute for the approved normative vectors.
- Transport coordinates are outside this profile.
- Dynamic schemas or fields beyond the reviewed contracts are not implied.
Profile
ENZAN-CANONICAL-JSON-v1 makes the same approved logical value produce the same bytes for local hashing and signing. The generated pipeline below is the reviewed high-level sequence.
Validation and normalization
Strict contracts reject unknown members, duplicate member names, invalid Unicode, non-finite numbers, and unsafe integral JSON numbers. Schema-defined object member names use ASCII identifiers.
String preprocessing converts CRLF, lone carriage return, U+2028, and U+2029 line boundaries to LF before Unicode 15.1 NFC normalization. NFKC is not used. Array order is preserved unless a schema explicitly declares set semantics.
In the v0.1 profile, tags is the set-valued field: entries are normalized, empty values are rejected, exact duplicates are removed, and values are sorted before JCS.
Bytes, hashes, and signatures
RFC 8785 JCS supplies deterministic JSON member ordering and number and string serialization. The resulting text is encoded as UTF-8 without a byte-order mark.
Each hash and signing purpose uses its specified ASCII domain separator. Request payload hashes use purpose-separated SHA-256. Authenticated requests use pure Ed25519 over the purpose-prefixed canonical request envelope; they do not use Ed25519ph or an additional message prehash.
Normative conformance vectors, including canonical-equivalence and non-equivalence cases, remain defined by the approved v0.1 architecture record. This page records no transport coordinates or executable signing request.
Canonical pipeline
- strict schema validation
- line-ending normalization
- Unicode 15.1 NFC normalization
- set-field rules for fields whose schema declares set semantics
- RFC 8785 JCS serialization
- UTF-8 encoding without a byte-order mark
- purpose-separated SHA-256 hashing where a digest is required
- pure Ed25519 signing for signed messages