Skip to main content

Mesh Network

Hook uses a WireGuard-based mesh network to provide secure, encrypted communication between all infrastructure nodes. This enables nodes to communicate as if they were on the same local network, regardless of their physical location.

Overview

The mesh network provides:
  • Encrypted tunnels between all nodes using WireGuard
  • Private IP addressing (10.100.0.0/24 by default)
  • Automatic peer discovery and configuration
  • Network isolation for sensitive services

Architecture

Mesh Server (Helm)

The Helm server acts as the mesh network coordinator:

Mesh Clients

All other nodes (Corsair, Nameserver, Payload Server) connect as mesh clients:

Enabling the Mesh Network

On Helm

The mesh network can be enabled at startup or via gRPC:

On Corsair/Other Nodes

Nodes connect to the mesh by specifying the Helm address:

Peer Registration

When a node connects to the mesh:
  1. Generate Keys: Client generates WireGuard keypair
  2. Register: Client sends public key to Helm via gRPC
  3. Assign IP: Helm assigns a mesh IP from the pool
  4. Configure: Both sides configure WireGuard peers
  5. Connect: Tunnel is established

Peer Communication

Peer Server

Each mesh node runs a peer server for direct communication:

Ping/Pong

Nodes can ping each other to verify connectivity:

Service Access Over Mesh

Internal Services

These services are only accessible over the mesh network:

Firewall Rules

Helm automatically configures firewall rules to restrict internal services:

Mesh Status

Get Mesh Status

Response includes:
  • Server configuration
  • Network CIDR
  • Total and active peer count
  • Individual peer status

List Peers

Configuration Persistence

Mesh configuration is saved locally for reconnection:

Interface Naming

Hook uses hookN interface names (hook0, hook1, etc.):

Next Steps