1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
//! **`uor_addr::sexp` — the S-expression realization of UOR-ADDR**
//! (ARCHITECTURE.md "Format-specific realizations" § `uor-addr-sexp`).
//!
//! S-expression typed-input content-addressing under Rivest's canonical
//! S-expression form, with the σ-projection bound to
//! `prism::crypto::Sha256Hasher`.
//!
//! ## Authoritative sources
//!
//! - **Canonical S-expressions** — Ronald L. Rivest, *S-expressions*,
//! May 4 1997 draft, archived at
//! <https://people.csail.mit.edu/rivest/Sexp.txt>. I-D form at
//! <https://datatracker.ietf.org/doc/html/draft-rivest-sexp-00>.
//! - **SPKI canonical form citation** — IETF RFC 2693 §3
//! *SPKI Certificate Theory*
//! (<https://datatracker.ietf.org/doc/html/rfc2693#section-3>).
//! - **SHA-256 σ-projection** — NIST FIPS 180-4
//! (<https://nvlpubs.nist.gov/nistpubs/FIPS/NIST.FIPS.180-4.pdf>).
//!
//! ## Grammar
//!
//! ```text
//! SExprValue ::= Atom(bytes) — symbolic atoms (UTF-8 bytes)
//! | Cons(SExprValue, SExprValue)
//! | Nil
//! ```
//!
//! The wire-format input is canonical S-expression syntax — atoms as
//! `<n>:<bytes>` length-prefixed byte sequences (Rivest's canonical
//! form), lists as parenthesized sequences, nil as `()`. The parser also
//! admits the Lisp-style sugared form `(a b c)`.
//!
//! ## Canonicalization (ADR-060 streaming)
//!
//! The realization no longer materializes a structurally-tagged byte
//! form. [`SExprCanon`] is a [`prism::uor_foundation::pipeline::ChunkSource`] over the
//! borrowed input that emits Rivest canonical bytes on demand — atoms as
//! `<n>:<bytes>`, lists as `(s₁ s₂ … sₙ)`, nil as `()` — and ψ₉ folds
//! those chunks through the σ-axis. There is no input size, atom-width,
//! element-count, or nesting-depth ceiling.
pub use ;
pub use ;
pub use canonicalize;
pub use ;
pub use ;
/// The shared, format-independent ψ-tower (re-exported for convenience;
/// canonical path is [`crate::resolvers::AddressResolverTuple`]).
pub use crateAddressResolverTuple;