---
typeId: req
recordId: benac-crypto-005
fields:
  title: DRISL document hashing and signing
  statement: 'Benac shall use DRISL as the baseline deterministic structured
    encoding for all structured Benac objects that are content-addressed,
    signed, exported as immutable, included in tamper-evident records, or
    verified across implementations. For such objects, Benac shall validate the
    logical Benac object and encode that logical object as DRISL before hashing
    or signing. Couch/Pouch-compatible documents are operational storage and
    replication envelopes. Couch/Pouch-managed metadata, including _id, _rev,
    revision history, conflict metadata, sync state, local availability, local
    verification status, local UI state, and host-local indexes, shall not be
    included in the logical payload used for CIDs or signatures. If a Benac
    schema needs analogous information, it shall define explicit logical payload
    fields for that information rather than relying on Couch/Pouch-managed
    metadata. The baseline JSON projection of CID links shall use the AT-style
    {"$link": "b..."} representation. CIDs inside DRISL shall be encoded using
    CBOR Tag 42 over a byte string containing 0x00 followed by the binary DASL
    CID bytes. Signed claim envelopes and signed claim payloads shall be signed
    over DRISL bytes or over another explicitly defined byte sequence derived
    from DRISL.'
  rationale: Different JSON formatting, document-store metadata, Couch/Pouch
    revision state, or host-local fields must not produce different identities
    for the same logical object. DRISL gives independent implementations the
    same structured bytes.
  verification: DRISL encoding vectors match across Host Platforms. Couch/Pouch
    documents with different _id, _rev, local state, sync state, or field
    ordering but the same logical payload produce the same DRISL bytes and
    structured CID. Payload mutations produce different CIDs. DRISL
    rejection vectors cover unsupported tags, non-string map keys, unsupported
    simple values, trailing bytes, concatenated objects, and other DRISL-invalid
    encodings. CID-in-DRISL vectors shall verify CBOR Tag 42 encoding with
    byte-string payload 0x00 || binary_dasl_cid and shall reject malformed Tag
    42 payloads.
  testable: true
  status: draft
  area: BENAC-CRYPTO
  sourceDocument: /home/johnb/Downloads/benac_syrs_v0_4_integrated_authentication.md
  sourceVersion: v0.4
  sourceSections:
    - 10.1 Cryptographic identity, content identity, and provenance foundation
  order: 5
---
