Versions in this module Expand all Collapse all v1 v1.0.0 Apr 25, 2024 Changes in this version + const ErrLinkAlreadyConfigured + const ErrLinkMaxBackoffInvalid + const ErrLinkNotConfigured + const ErrLinkPasswordInvalid + const ErrLinkPinnedKeyInvalid + const ErrLinkPriorityInvalid + const ErrLinkUnrecognisedSchema + const ProtocolVersionMajor + const ProtocolVersionMinor + type AddHandler interface + AddHandler func(name, desc string, args []string, handlerfunc AddHandlerFunc) error + type AddHandlerFunc func(json.RawMessage) (interface{}, error) + type AllowedPublicKey ed25519.PublicKey + type Core struct + func New(cert *tls.Certificate, logger Logger, opts ...SetupOption) (*Core, error) + func (c *Core) AddPeer(u *url.URL, sintf string) error + func (c *Core) Address() net.IP + func (c *Core) CallPeer(u *url.URL, sintf string) error + func (c *Core) GetPaths() []PathEntryInfo + func (c *Core) GetPeers() []PeerInfo + func (c *Core) GetSelf() SelfInfo + func (c *Core) GetSessions() []SessionInfo + func (c *Core) GetTree() []TreeEntryInfo + func (c *Core) Listen(u *url.URL, sintf string) (*Listener, error) + func (c *Core) MTU() uint64 + func (c *Core) PublicKey() ed25519.PublicKey + func (c *Core) ReadFrom(p []byte) (n int, from net.Addr, err error) + func (c *Core) RemovePeer(u *url.URL, sintf string) error + func (c *Core) RetryPeersNow() + func (c *Core) SetAdmin(a AddHandler) error + func (c *Core) SetLogger(log Logger) + func (c *Core) SetPathNotify(notify func(ed25519.PublicKey)) + func (c *Core) Stop() + func (c *Core) Subnet() net.IPNet + func (c *Core) WriteTo(p []byte, addr net.Addr) (n int, err error) + type DebugGetPeersRequest struct + Key string + type DebugGetPeersResponse map[string]interface + type DebugGetSelfRequest struct + Key string + type DebugGetSelfResponse map[string]interface + type DebugGetTreeRequest struct + Key string + type DebugGetTreeResponse map[string]interface + type GetNodeInfoRequest struct + Key string + type GetNodeInfoResponse map[string]json.RawMessage + type ListenAddress string + type Listener struct + Cancel context.CancelFunc + func (l *Listener) Addr() net.Addr + func (l *Listener) Close() error + type Logger interface + Debugf func(string, ...interface{}) + Debugln func(...interface{}) + Errorf func(string, ...interface{}) + Errorln func(...interface{}) + Infof func(string, ...interface{}) + Infoln func(...interface{}) + Printf func(string, ...interface{}) + Println func(...interface{}) + Traceln func(...interface{}) + Warnf func(string, ...interface{}) + Warnln func(...interface{}) + type NodeInfo map[string]interface + type NodeInfoPrivacy bool + type PathEntryInfo struct + Key ed25519.PublicKey + Path []uint64 + Sequence uint64 + type Peer struct + SourceInterface string + URI string + type PeerInfo struct + Coords []uint64 + Inbound bool + Key ed25519.PublicKey + LastError error + LastErrorTime time.Time + Port uint64 + Priority uint8 + RXBytes uint64 + Root ed25519.PublicKey + TXBytes uint64 + URI string + Up bool + Uptime time.Duration + type SelfInfo struct + Key ed25519.PublicKey + RoutingEntries uint64 + type SessionInfo struct + Key ed25519.PublicKey + RXBytes uint64 + TXBytes uint64 + Uptime time.Duration + type SetupOption interface + type TreeEntryInfo struct + Key ed25519.PublicKey + Parent ed25519.PublicKey + Sequence uint64