Expand description
Encrypted mailbox and latest-value slot transport fan-out.
enlace exposes two namespace modes over the same transport set:
Namespaceis shared-seed mode. Use it when every participant can safely share one 32-byte secret and should have equal read/write access to the same mailbox and slot names. This fits small trusted clusters, local recovery slots, and deployments where membership is already controlled outside the library. Optional signing keys can authenticate incoming records, but the shared seed still grants access to all peers that know it.PeerNamespaceis public-key mode. Use it when peers have separate long-term identities, pair by exchangingPeerCardvalues, and need per-peer trust, revocation, pairwise envelopes, caller-managed group keys, or iroh endpoint allowlists. Caller code owns identity persistence, card exchange, authorization policy, group membership, and group-key rotation.
HTTP and iroh transports can carry mailbox messages in both modes. HTTP, DHT, pkarr, and iroh can carry slots; DHT and pkarr are latest-record slot transports and do not provide mailbox delivery.
Re-exports§
pub use config::PkarrConfig;pub use config::BasicAuth;pub use config::HttpConfig;pub use config::Config;pub use config::ConfiguredTransport;pub use config::IrohEndpointAddr;pub use config::DhtBootstrapCacheConfig;pub use config::DhtConfig;pub use config::IrohConfig;pub use config::IrohRelayMode;pub use error::OpenError;pub use error::RecvError;pub use error::SealError;pub use error::SendError;pub use error::SlotError;pub use error::TransportError;pub use kdf::ChannelKind;pub use kdf::NameError;pub use kdf::TransportKind;pub use mailbox::Mailbox;pub use mailbox::RecvMessage;pub use mailbox::SendReport;pub use namespace::Namespace;pub use peer::GROUP_ID_LEN;pub use peer::GROUP_KEY_ID_LEN;pub use peer::GROUP_KEY_SECRET_LEN;pub use peer::GroupEnvelope;pub use peer::GroupEnvelopeEntry;pub use peer::GroupEnvelopeError;pub use peer::GroupEnvelopeMessage;pub use peer::GroupId;pub use peer::GroupKey;pub use peer::GroupKeyError;pub use peer::GroupKeyId;pub use peer::PEER_ID_LEN;pub use peer::PeerCard;pub use peer::PeerCardError;pub use peer::PeerConfig;pub use peer::PeerEnvelope;pub use peer::PeerEnvelopeError;pub use peer::PeerEnvelopeMessage;pub use peer::PeerId;pub use peer::PeerIdentity;pub use peer::PeerMailbox;pub use peer::PeerMailboxMessage;pub use peer::PeerNamespace;pub use peer::PeerRecipientEnvelope;pub use peer::PeerSendError;pub use peer::PeerSendReport;pub use peer::PeerSlot;pub use peer::PeerSlotError;pub use peer::PeerSlotPutReport;pub use peer::PeerSlotScope;pub use peer::PeerSlotValue;pub use peer::PeerSlotWatch;pub use peer::TrustError;pub use peer::TrustedPeer;pub use slot::PutReport;pub use slot::Slot;pub use slot::SlotValue;pub use slot::SlotWatch;pub use state::InMemoryStateStore;pub use state::State;pub use state::StateError;pub use state::StateStore;pub use transports::DhtTransport;pub use transports::HttpTransport;pub use transports::IrohTransport;pub use transports::PkarrTransport;pub use transports::EndpointHealth;pub use transports::HealthReport;pub use transports::HealthState;pub use transports::HealthTransition;pub use transports::HealthTransitionKind;pub use transports::MailboxTransport;pub use transports::SlotTransport;pub use transports::SlotWatchStream;pub use transports::Transport;pub use transports::TransportHealth;
Modules§
- config
- coordinator
- crypto
- AEAD seal/unseal, ed25519 sign/verify, HKDF subkey expansion, and constant-time slice comparison.
- dedup
- Best-effort dedup of recently-seen sealed payloads.
- error
- Error enums for the public API.
- guard
- kdf
- Channel addressing.
- mailbox
- namespace
- peer
- Public-key peer identity types.
- slot
- state
- Persistent endpoint state used by slot writers and the iroh adapter.
- transports