Skip to main content

Crate codec_jcs

Crate codec_jcs 

Source
Expand description

JSON Canonicalization Scheme helpers.

Object member ordering and finite floating-point formatting follow RFC 8785. The raw-text API rejects duplicate object member names and malformed JSON. Integer tokens that serde_json retains exactly as i64 or u64 are additionally rejected outside [-(2^53)+1, (2^53)-1]; numbers parsed through binary64, including decimal/exponent forms and magnitudes above u64::MAX, follow RFC 8785’s ECMAScript rounding semantics.

Enums§

JcsError
Error returned when JSON canonicalization (JCS) fails.

Constants§

MAX_NESTING_DEPTH
Maximum array/object nesting depth accepted by canonicalize_trusted_json_value.

Functions§

canonicalize_jsonDeprecated
Deprecated alias for canonicalize_trusted_json_value.
canonicalize_json_text
Parse and canonicalize one untrusted JSON text according to RFC 8785.
canonicalize_trusted_json_value
Canonicalize a trusted, already-materialized JSON value according to RFC 8785 (JSON Canonicalization Scheme).