Documentation ¶
Index ¶
- Constants
- func DeleteName(name string) error
- func ListConfigNames() ([]string, error)
- func MigrateUnencryptedConfigs()
- func NameFromPath(path string) (string, error)
- func PathIsEncrypted(path string) bool
- func TunnelNameIsLess(a, b string) bool
- func TunnelNameIsValid(name string) bool
- type Bytes
- type Config
- func (conf *Config) DeduplicateNetworkEntries()
- func (config *Config) Delete() error
- func (config *Config) Path() (string, error)
- func (conf *Config) Redact()
- func (config *Config) Save(overwrite bool) error
- func (conf *Config) ToUAPI() (uapi string, dnsErr error)
- func (conf *Config) ToWgQuick() string
- type Endpoint
- type HandshakeTime
- type IPCidr
- type Interface
- type ParseError
- type Peer
- type PrivateKey
- type PublicKey
- type StoreCallback
Constants ¶
View Source
const PrivateKeyLength = 32
View Source
const PublicKeyLength = 33
Variables ¶
This section is empty.
Functions ¶
func DeleteName ¶
func ListConfigNames ¶
func MigrateUnencryptedConfigs ¶
func MigrateUnencryptedConfigs()
func NameFromPath ¶
func PathIsEncrypted ¶
func TunnelNameIsLess ¶
func TunnelNameIsValid ¶
Types ¶
type Config ¶
func LoadFromName ¶
func LoadFromPath ¶
func (*Config) DeduplicateNetworkEntries ¶
func (conf *Config) DeduplicateNetworkEntries()
type HandshakeTime ¶
func (HandshakeTime) IsEmpty ¶
func (t HandshakeTime) IsEmpty() bool
func (HandshakeTime) String ¶
func (t HandshakeTime) String() string
type ParseError ¶
type ParseError struct {
// contains filtered or unexported fields
}
func (*ParseError) Error ¶
func (e *ParseError) Error() string
type PrivateKey ¶
type PrivateKey [PrivateKeyLength]byte
func NewPresharedKey ¶
func NewPresharedKey() (*PrivateKey, error)
func NewPrivateKey ¶
func NewPrivateKey() (*PrivateKey, error)
func NewPrivateKeyFromString ¶
func NewPrivateKeyFromString(b64 string) (*PrivateKey, error)
func (*PrivateKey) HexString ¶
func (k *PrivateKey) HexString() string
func (*PrivateKey) IsZero ¶
func (k *PrivateKey) IsZero() bool
func (*PrivateKey) Public ¶
func (k *PrivateKey) Public() *PublicKey
func (*PrivateKey) String ¶
func (k *PrivateKey) String() string
type StoreCallback ¶
type StoreCallback struct {
// contains filtered or unexported fields
}
func RegisterStoreChangeCallback ¶
func RegisterStoreChangeCallback(cb func()) *StoreCallback
func (*StoreCallback) Unregister ¶
func (cb *StoreCallback) Unregister()
Source Files ¶
Click to show internal directories.
Click to hide internal directories.