Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Crate: kinetic-host

Stage: 13

Reading Time: 45 mins

Depends On: kinetic-core, kinetic-network, kinetic-storage


What Is This?

Note

kinetic-host is the binary for domain owners who want to publicly serve content through the Kinetic network. Unlike the infrastructure node (kinetic-node) which is a passive DHT relay, the host is an active content server — it receives real HTTP traffic from Kinetic users and forwards it to a local web backend.


How It Differs From the Other Binaries

Featurekinetic-nodekinetic-hostkinetic-daemon
RoleDHT backboneContent serverUser client
P2P identityStatic Ed25519Dual: static host key + ephemeral PoWEphemeral PoW
Serves HTTPNoYes — reverse proxies to local backendNo (proxy client only)
User-facing API/health, /peer_id/health, /peer_idFull registration API
DNS resolverNoNoYes
mDNSDisabledConfig-drivenConfig-driven
API port160031600416000

What Makes It Uniquely Complex

  1. Dual-key architecture: Has both a static long-lived host key (host.key) and an ephemeral epoch-bound PoW keypair. The host key is the permanent identity visible to clients. The PoW key is the active libp2p peer identity for Sybil resistance.
  2. Hot-swap network loop: When the Drand epoch advances and the current PoW key expires, the host mines a new keypair and restarts the entire NetworkEventLoop without downtime — traffic continues flowing during the swap.
  3. HostRoutingRecord publishing: Every 30 seconds, publishes a signed record to the DHT mapping its permanent host key → current ephemeral Peer ID. Clients look up the host key and use this record to find the current P2P address.
  4. Reverse proxy: Receives ProxyRequest messages over libp2p, forwards them to a local HTTP server, and returns the response over the same P2P channel.

Files

  • 02_main.md — Boot sequence with focus on dual identity + hot-swap wiring
  • 03_heartbeat.md — PoW hot-swap and HostRoutingRecord publisher (most unique code)
  • 04_proxy.md — P2P reverse proxy: path validation, body size limits, backend forwarding
  • 05_gossip_service_api.md — Governance gossip (simpler than node), service manager, health API