networker

package
v0.0.0-...-851e5e8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 28, 2024 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Failing

type Failing struct{}

func (Failing) Allow

func (Failing) Allow(mesh.Machine) error

func (Failing) Block

func (Failing) Block(mesh.Machine) error

func (Failing) Connect

func (Failing) Connect(netip.Addr, string) error

func (Failing) ConnectionStatus

func (Failing) ConnectionStatus() (networker.ConnectionStatus, error)

func (Failing) DenyIPv6

func (Failing) DenyIPv6() error

func (Failing) DisableFirewall

func (Failing) DisableFirewall() error

func (Failing) DisableRouting

func (Failing) DisableRouting()

func (Failing) Disconnect

func (Failing) Disconnect() error

func (Failing) EnableFirewall

func (Failing) EnableFirewall() error

func (Failing) EnableRouting

func (Failing) EnableRouting()

func (Failing) IsMeshnetActive

func (Failing) IsMeshnetActive() bool

func (Failing) IsNetworkSet

func (Failing) IsNetworkSet() bool

func (Failing) IsVPNActive

func (Failing) IsVPNActive() bool

func (Failing) LastServerName

func (Failing) LastServerName() string

func (Failing) PermitIPv6

func (Failing) PermitIPv6() error

func (Failing) Refresh

func (Failing) Refresh(mesh.MachineMap) error

func (Failing) SetAllowlist

func (Failing) SetAllowlist(config.Allowlist) error

func (Failing) SetDNS

func (Failing) SetDNS([]string) error

func (Failing) SetKillSwitch

func (Failing) SetKillSwitch(config.Allowlist) error

func (Failing) SetLanDiscovery

func (Failing) SetLanDiscovery(bool)

func (Failing) SetLanDiscoveryAndResetMesh

func (Failing) SetLanDiscoveryAndResetMesh(bool, mesh.MachinePeers)

func (Failing) SetVPN

func (Failing) SetVPN(vpn.VPN)

func (Failing) Start

func (Failing) Stop

func (Failing) Stop() error

func (Failing) UnSetMesh

func (Failing) UnSetMesh() error

func (Failing) UnsetAllowlist

func (Failing) UnsetAllowlist() error

func (Failing) UnsetDNS

func (Failing) UnsetDNS() error

func (Failing) UnsetKillSwitch

func (Failing) UnsetKillSwitch() error

type Mock

type Mock struct {
	Dns               []string
	Allowlist         config.Allowlist
	VpnActive         bool
	MeshActive        bool
	ConnectRetries    int
	LanDiscovery      bool
	MeshPeers         mesh.MachinePeers
	MeshnetRetries    int
	SetDNSErr         error
	SetAllowlistErr   error
	UnsetAllowlistErr error
}

func (*Mock) ConnectionStatus

func (*Mock) ConnectionStatus() (networker.ConnectionStatus, error)

func (*Mock) DenyIPv6

func (*Mock) DenyIPv6() error

func (*Mock) DisableFirewall

func (*Mock) DisableFirewall() error

func (*Mock) DisableRouting

func (*Mock) DisableRouting()

func (*Mock) EnableFirewall

func (*Mock) EnableFirewall() error

func (*Mock) EnableRouting

func (*Mock) EnableRouting()

func (*Mock) IsMeshnetActive

func (m *Mock) IsMeshnetActive() bool

func (*Mock) IsNetworkSet

func (*Mock) IsNetworkSet() bool

func (*Mock) IsVPNActive

func (m *Mock) IsVPNActive() bool

func (*Mock) LastServerName

func (*Mock) LastServerName() string

func (*Mock) PermitIPv6

func (*Mock) PermitIPv6() error

func (*Mock) SetAllowlist

func (m *Mock) SetAllowlist(allowlist config.Allowlist) error

func (*Mock) SetDNS

func (m *Mock) SetDNS(nameservers []string) error

func (*Mock) SetKillSwitch

func (*Mock) SetKillSwitch(config.Allowlist) error

func (*Mock) SetLanDiscovery

func (m *Mock) SetLanDiscovery(enabled bool)

func (*Mock) SetLanDiscoveryAndResetMesh

func (m *Mock) SetLanDiscoveryAndResetMesh(enabled bool, peers mesh.MachinePeers)

func (*Mock) SetVPN

func (*Mock) SetVPN(vpn.VPN)

func (*Mock) Stop

func (*Mock) Stop() error

func (*Mock) UnSetMesh

func (*Mock) UnSetMesh() error

func (*Mock) UnsetAllowlist

func (m *Mock) UnsetAllowlist() error

func (*Mock) UnsetDNS

func (*Mock) UnsetDNS() error

func (*Mock) UnsetKillSwitch

func (*Mock) UnsetKillSwitch() error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL