Expand description
KROT relay server library.
Public API mirrors what the krot-server binary uses at startup: a
Server struct that owns the QUIC endpoint, the persistent identity,
the tunnel registry and the authorized-keys index. Tests and embeddings
construct one via Server::start with a ServerConfig.
Re-exports§
pub use config::DomainTls;pub use config::Mode;pub use config::ServerConfig;pub use error::ServerError;pub use identity::ServerIdentity;pub use server::Server;
Modules§
- admin
- Admin-token issuance and single-use consumption (§14).
- admin_
api - §16.4 Structured admin API.
- config
- Server configuration.
- domain
- DomainMode routing plane: plain HTTP on port 80 (Host-header based) and HTTPS on port 443 (SNI-passthrough).
- error
- Unified server error type.
- fsync
- Parent-directory fsync after atomic rename.
- handshake
- Control-stream handshake: dispatch between authenticated sessions and bootstrap enrollment (§7.1, §14).
- identity
- Persistent server identity for IpMode (§15.3).
- keys
authorized_keysparser and in-memory index (§13).- metrics
- Process-wide counters and gauges exposed on
/admin/v1/metricsin Prometheus text-exposition format (§16.4). - peer_
lookup - §16.3.4 cross-relay collision detection.
- peers
- §16.3.2 static federated-peer list.
- rate
- Per-identity rate limiting (§9).
- registry
- Tunnel registry: label-indexed HTTP tunnels + port-pool TCP tunnels.
- server
Server— top-level orchestration.- session
- Per-connection session loop: dispatch
ClientFrames to registry actions and reply withServerFrames. - sockets
- Per-core socket helpers using
SO_REUSEPORT. - tunnel
- Public TCP listener for one IpMode tunnel.