Documentation ¶
Index ¶
Constants ¶
View Source
const (
OSLinux = "Linux"
)
All OS types, currently only used to distinguish Linux.
Variables ¶
View Source
var LoadOptions = ini.LoadOptions{ Insensitive: true, AllowNonUniqueSections: true, AllowShadows: true, }
LoadOptions contains the options to load the config correctly.
Functions ¶
This section is empty.
Types ¶
type Config ¶
Config reflects a network configuration file.
func LoadConfigFromFile ¶
LoadConfigFromFile reads Config from given filePath.
type Peer ¶
type Peer struct { wireguard.Interface `ini:"Peer"` wireguard.Peer `ini:"Peer"` ID string `ini:"ID"` LocalSubnets string `int:"LocalSubnets"` PublicInterface string `ini:"PublicInterface,omitempty"` OS string `ini:"OS,omitempty"` }
Peer reflects a Peer section within a network configuration file.
func (*Peer) AllowedIPsForPeer ¶
AllowedIPsForPeer returns the computed AllowedIPs at the perspective of given peer.
func (*Peer) IsBounceServer ¶
IsBounceServer returns true if the peer is capable of traffic relaying.
Click to show internal directories.
Click to hide internal directories.