Versions in this module Expand all Collapse all v1 v1.4.8 Aug 10, 2026 Changes in this version + func AddClientHandler(im *InterfaceManager, smdClient smdclient.SMDClientInterface) http.HandlerFunc + func AddWireGuardPeer(interfaceID, publicKey, vpnIP, clientIP string) error + func GetUsableIP(network *net.IPNet) (net.IP, error) + type IPAllocator struct + func NewIPAllocator(cidr string) (*IPAllocator, error) + func (a *IPAllocator) IsAllocated(ipAddr net.IPAddr) bool + func (a *IPAllocator) NextAvailable() (net.IPAddr, error) + func (a *IPAllocator) Release(ipAddr net.IPAddr) error + func (a *IPAllocator) Reserve(ipAddr net.IPAddr) error + type InterfaceManager struct + func NewInterfaceManager(name string, localIp net.IP, network *net.IPNet) *InterfaceManager + func (m *InterfaceManager) AddPeer(peerName, publicKey, vpnIP, clientIP string) error + func (m *InterfaceManager) GetInterfaceName() string + func (m *InterfaceManager) GetPeers() map[string]PeerConfig + func (m *InterfaceManager) GetServerConfig() (ServerConfig, error) + func (m *InterfaceManager) IpForPeer(peerName string, publicKey string) string + func (m *InterfaceManager) PublicKey() (string, error) + func (m *InterfaceManager) RemovePeer(peerName string) error + func (m *InterfaceManager) StartServer() error + func (m *InterfaceManager) StopServer() error + type PeerConfig struct + IP net.IPAddr + PublicKey string + type PublicKeyRequest struct + PublicKey string + type ServerConfig struct + IP string + Port string + PublicKey string + type Store interface + GetInterfaceName func() string + GetServerConfig func() (ServerConfig, error) + IpForPeer func(peerName, publicKey string) string + type WGResponse struct + ClientVPNIP string + Message string + ServerIP string + ServerPort string + ServerPubKey string