Skip to main content

Crate fabric_protocol

Crate fabric_protocol 

Source
Expand description

ForgeWire wire protocol primitives.

Stage C.1: ed25519 sign + verify over canonical JSON envelopes, byte-compatible with the existing Python implementation in scripts/remote/runner/identity.py and scripts/remote/runner/runner_capabilities.py::canonical_payload.

The canonical form is serde_json with sorted keys and the compact separators (',', ':'), matching Python’s json.dumps(payload, sort_keys=True, separators=(",", ":")).

Enums§

ProtocolError
Errors surfaced by the protocol layer.

Functions§

canonicalize
Canonical-JSON encoding of a serde_json::Value.
sign_envelope_hex
Convenience: sign an envelope (object) with a hex secret key.
sign_payload_hex
Sign payload with a hex-encoded 32-byte ed25519 secret key.
verify_envelope_hex
Convenience: verify a signed envelope (object) using a hex public key and hex signature; canonicalizes the envelope before verifying.
verify_signature_hex
Verify an ed25519 signature over payload using a hex-encoded public key.