Expand description
uor_addr::json — the JSON realization of UOR-ADDR
(ARCHITECTURE.md “Format-specific realizations” § uor-addr-json).
JSON typed-input content-addressing under JCS-RFC8785 §3 + Unicode
NFC, with the σ-projection bound to prism::crypto::Sha256Hasher.
§Authoritative sources
- JSON syntax — IETF RFC 8259 The JavaScript Object Notation (JSON) Data Interchange Format (https://datatracker.ietf.org/doc/rfc8259/).
- Canonical form (JCS) — IETF RFC 8785 JSON Canonicalization Scheme (JCS) (https://datatracker.ietf.org/doc/rfc8785/).
- Unicode NFC normalization — Unicode Standard Annex #15 Unicode Normalization Forms (https://www.unicode.org/reports/tr15/).
- ECMA-262 numeric serialization — invoked by JCS-RFC8785 §3.2.2.3 (https://datatracker.ietf.org/doc/html/rfc8785#section-3.2.2.3).
- SHA-256 σ-projection — NIST FIPS 180-4 (https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.180-4.pdf).
- Reference baseline — https://mcp.uor.foundation/tools/encode_address κ-label fixtures.
§End-to-end through prism’s typed-iso surface (ADR-060)
canonicalizeparses raw JSON and emits the JCS-RFC8785 + Unicode-NFC canonical-form bytes into anallocbuffer at the host boundary (object members sorted by key; no width / count caps).addresswraps those bytes in the borrowedJsonCarrierand runsAddressModel’sforward(): the ψ-chain verbaddress_inferencethreads the carrier through the sharedAddressResolverTuple(ADR-036), and ψ₉ folds the canonical bytes throughSha256Hasherin one σ-projection to derive the κ-label.addressreturns thecrate::AddressOutcomecarrying thecrate::AddressLabelκ-label + replayable TC-05 witness — well-formed JSON always yields exactly one label.
§Why this module exists
Per ARCHITECTURE.md, UOR-ADDR is a body of PrismModel
declarations specialized to typed content-addressing across
formats with bounded recursive structural typing. Each format
ships its concrete specialization (this module for JSON;
crate::sexp for S-expressions; future modules per the
demand-driven clause of ADR-031). The common surface
(crate::common) names the shared trait, output shape, and
cost-model commitment; each format declares its own concrete
prism_model!, verb!, and resolver! invocations because the
SDK macros emit per-declaration types.
Re-exports§
pub use model::AddressModel;pub use model::AddressModelBlake3;pub use model::AddressModelKeccak256;pub use model::AddressModelSha3_256;pub use model::AddressModelSha512;pub use model::AddressRoute;pub use pipeline::address;pub use pipeline::address_blake3;pub use pipeline::address_keccak256;pub use pipeline::address_sha3_256;pub use pipeline::address_sha512;pub use pipeline::AddressFailure;pub use pipeline::AddressOutcome;pub use pipeline::AddressWitness;pub use pipeline::VerifyError;pub use shapes::MAX_JSON_DEPTH;pub use value::JsonCarrier;pub use value::canonicalize;pub use value::ArrayIter;pub use value::JsonValue;pub use value::JsonValueRef;pub use value::ObjectIter;pub use verbs::address_inference;pub use verbs::VERB_TERMS_ADDRESS_INFERENCE;pub use crate::bounds::AddrBounds;pub use crate::resolvers::AddressResolverTuple;
Modules§
- model
json::AddressModel*— the JSON realization’sPrismModeldeclarations, one per admissible σ-axis (crate::hash). Each binds the sharedAddressResolverTupleψ-tower and the axis’s capacity profile (AddrBoundsfor the 32-byte axes,AddrBounds64for sha512); the input is the ADR-060 borrowed-carrier handleJsonCarrier.AddressModel(sha256) is the default.- pipeline
json::address*— the JSON realization’s public entry points, one per admissible σ-axis (crate::hash).- shapes
- Substitution-axis selections.
- value
- JSON typed input (ADR-023 amended by ADR-060) with JCS-RFC8785 + Unicode NFC canonical-form byte output.
- verbs
uor-addr’s ψ-chain content-address derivation verbs (wiki ADR-024, ADR-035, ADR-036) — one per admissible σ-axis.
Structs§
- Sha256
Hasher - Canonical
Hasher<32>selection for the address-derivation pipeline. Re-exported from the Prism standard library; see wiki ADR-031. FIPS-180-4 SHA-256 hasher. 32-byte digest.