MCPcopy Create free account

hub / github.com/WireGuard/wgctrl-go / functions

Functions219 in github.com/WireGuard/wgctrl-go

↓ 1 callersMethodSetIP
SetIP method sets family, address, and port to the given IPv4 or IPv6 address and port. All other members of the structure are set to zero.
internal/wgwindows/internal/ioctl/winipcfg_windows.go:38
↓ 1 callersFunctionbuildBatches
buildBatches produces a batch of configs from a single config, if needed.
internal/wglinux/configure_linux.go:82
↓ 1 callersFunctionconfigAttrs
configAttrs creates the required encoded netlink attributes to configure the device specified by name using the non-nil fields in cfg.
internal/wglinux/configure_linux.go:20
↓ 1 callersMethodconfigureDevice
configureDevice configures a device specified by its path.
internal/wguser/configure.go:15
↓ 1 callersMethodcurPeer
curPeer returns the current Peer being parsed so its fields can be populated.
internal/wguser/parse.go:139
↓ 1 callersFunctiondurPtr
(d time.Duration)
internal/wguser/client_test.go:128
↓ 1 callersFunctiondurPtr
(d time.Duration)
internal/wglinux/client_linux_test.go:344
↓ 1 callersFunctionencodePeer
encodePeer returns a function to encode PeerConfig nested attributes.
internal/wglinux/configure_linux.go:173
↓ 1 callersFunctionencodeSockaddr
encodeSockaddr returns a function which encodes a net.UDPAddr as raw sockaddr_in or sockaddr_in6 bytes.
internal/wglinux/configure_linux.go:215
↓ 1 callersFunctiongenerateIPs
(n int)
client_integration_test.go:440
↓ 1 callersFunctionioctlIfgroupreq
ioctlIfgroupreq returns a function which performs the appropriate ioctl on fd to retrieve members of an interface group.
internal/wgopenbsd/client_openbsd.go:345
↓ 1 callersFunctionioctlIfgroupreq
ioctlIfgroupreq returns a function which performs the appropriate ioctl on fd to retrieve members of an interface group.
internal/wgfreebsd/client_freebsd.go:231
↓ 1 callersFunctionioctlWGDataIO
ioctlWGDataIO returns a function which performs the appropriate ioctl on fd to issue a WireGuard data I/O.
internal/wgopenbsd/client_openbsd.go:353
↓ 1 callersFunctionioctlWGDataIO
ioctlWGDataIO returns a function which performs the appropriate ioctl on fd to issue a WireGuard data I/O.
internal/wgfreebsd/client_freebsd.go:239
↓ 1 callersFunctionipsString
(ipns []net.IPNet)
client_integration_test.go:431
↓ 1 callersFunctionipsString
(ipns []net.IPNet)
cmd/wgctrl/main.go:86
↓ 1 callersFunctionisWGKind
isWGKind parses netlink attributes to determine if a link is a WireGuard device, then populates ok with the result.
internal/wglinux/client_linux.go:252
↓ 1 callersFunctionmarshal
(m List)
internal/wgfreebsd/internal/nv/encode.go:36
↓ 1 callersFunctionmergeDevices
mergeDevices merges Peer information from d into target. mergeDevices is used to deal with multiple incoming netlink messages for the same device.
internal/wglinux/parse_linux.go:293
↓ 1 callersFunctionnewClients
newClients configures wginternal.Clients for Linux systems.
os_linux.go:13
↓ 1 callersFunctionpack
pack packs a WGInterfaceIO and trailing WGPeerIO/WGAIPIO values in a contiguous byte slice to emulate the kernel module output.
internal/wgopenbsd/client_openbsd_test.go:314
↓ 1 callersFunctionpanicf
(format string, a ...interface{})
client_integration_test.go:462
↓ 1 callersFunctionpanicf
(format string, a ...interface{})
wgtypes/types_test.go:119
↓ 1 callersFunctionpanicf
(format string, a ...interface{})
internal/wgfreebsd/client_freebsd.go:255
↓ 1 callersFunctionparseAddr
parseAddr parses a net.IP from raw in_addr or in6_addr struct bytes.
internal/wglinux/parse_linux.go:194
↓ 1 callersMethodparseAddr
parseAddr parses a UDP address from a string.
internal/wguser/parse.go:231
↓ 1 callersFunctionparseAllowedIP
parseAllowedIP unpacks a net.IPNet from a WGAIP structure.
internal/wgopenbsd/client_openbsd.go:286
↓ 1 callersFunctionparseAllowedIP
parseAllowedIP unpacks a net.IPNet from a WGAIP structure.
internal/wgfreebsd/client_freebsd.go:325
↓ 1 callersFunctionparseAllowedIPs
parseAllowedIPs parses a slice of net.IPNet from a netlink attribute payload.
internal/wglinux/parse_linux.go:133
↓ 1 callersMethodparseCIDR
parseInt parses an address CIDR from a string.
internal/wguser/parse.go:246
↓ 1 callersFunctionparseDevice
parseDevice unpacks a Device from ifio, along with its associated peers and their allowed IPs.
internal/wgopenbsd/client_openbsd.go:162
↓ 1 callersFunctionparseDevice
parseDevice parses a Device and its Peers from an io.Reader.
internal/wguser/parse.go:48
↓ 1 callersFunctionparseDevice
parseDevice decodes the device from a FreeBSD name-value list (nvlist)
internal/wgfreebsd/client_freebsd.go:422
↓ 1 callersFunctionparseDevice
parseDevice parses a Device from a slice of generic netlink messages, automatically merging peer lists from subsequent messages into the Device from t
internal/wglinux/parse_linux.go:21
↓ 1 callersFunctionparseDeviceLoop
parseDeviceLoop parses a Device from a single generic netlink message.
internal/wglinux/parse_linux.go:53
↓ 1 callersFunctionparseEndpoint
parseEndpoint parses a peer endpoint from a wgh.WGIP structure.
internal/wgopenbsd/client_openbsd.go:305
↓ 1 callersFunctionparseEndpoint
parseEndpoint converts a struct sockaddr to a Go net.UDPAddr
internal/wgfreebsd/client_freebsd.go:271
↓ 1 callersFunctionparsePeer
parsePeer unpacks a wgtypes.Peer from a WGPeerIO structure.
internal/wgopenbsd/client_openbsd.go:249
↓ 1 callersFunctionparsePeer
parsePeer unpacks a wgtypes.Peer from a name-value list (nvlist).
internal/wgfreebsd/client_freebsd.go:376
↓ 1 callersFunctionparsePeer
parseAllowedIPs parses a wgtypes.Peer from a netlink attribute payload.
internal/wglinux/parse_linux.go:103
↓ 1 callersFunctionparseSockaddr
parseSockaddr parses a *net.UDPAddr from raw sockaddr_in or sockaddr_in6 bytes.
internal/wglinux/parse_linux.go:209
↓ 1 callersFunctionparseTimestamp
parseTimestamp parses a binary timestamp to a Go time.Time
internal/wgfreebsd/client_freebsd.go:359
↓ 1 callersMethodpeerParse
peerParse parses a key/value field into the current Peer.
internal/wguser/parse.go:144
↓ 1 callersFunctionprintDevice
(d *wgtypes.Device)
cmd/wgctrl/main.go:49
↓ 1 callersFunctionprintPeer
(p wgtypes.Peer)
cmd/wgctrl/main.go:65
↓ 1 callersFunctionshouldBatch
shouldBatch determines if a configuration is sufficiently complex that it should be split into batches.
internal/wglinux/configure_linux.go:68
↓ 1 callersFunctiontestFind
testFind produces a Client.find function for integration tests.
internal/wguser/conn_unix_test.go:54
↓ 1 callersFunctiontestListen
testListen creates a userspace device listener for tests, returning the directory where it can be found and a function to clean up its state.
internal/wguser/conn_unix_test.go:62
↓ 1 callersFunctionunmarshal
(nvl *C.struct_nvlist, out List)
internal/wgfreebsd/internal/nv/decode.go:23
↓ 1 callersFunctionunparseAllowedIP
(aip net.IPNet)
internal/wgfreebsd/client_freebsd.go:343
↓ 1 callersFunctionunparseConfig
unparseDevice encodes the device configuration as a FreeBSD name-value list (nvlist).
internal/wgfreebsd/client_freebsd.go:501
↓ 1 callersFunctionunparseEndpoint
(ep net.UDPAddr)
internal/wgfreebsd/client_freebsd.go:302
↓ 1 callersFunctionunparsePeerConfig
unparsePeerConfig encodes a PeerConfig to a name-value list (nvlist).
internal/wgfreebsd/client_freebsd.go:462
↓ 1 callersFunctionwriteConfig
writeConfig writes textual configuration to w as specified by cfg.
internal/wguser/configure.go:53
MethodClose
()
client_test.go:234
MethodClose
Close implements wginternal.Client.
internal/wgwindows/client_windows.go:136
MethodConfigureDevice
(name string, cfg wgtypes.Config)
client_test.go:240
MethodConfigureDevice
ConfigureDevice implements wginternal.Client.
internal/wgopenbsd/client_openbsd.go:225
MethodConfigureDevice
ConfigureDevice implements wginternal.Client.
internal/wguser/client.go:75
MethodConfigureDevice
ConfigureDevice implements wginternal.Client.
internal/wgwindows/client_windows.go:232
MethodConfigureDevice
ConfigureDevice implements wginternal.Client.
internal/wgfreebsd/client_freebsd.go:168
MethodConfigureDevice
ConfigureDevice implements wginternal.Client.
internal/wglinux/client_linux.go:128
MethodDevice
(name string)
client_test.go:236
MethodDevice
Device implements wginternal.Client.
internal/wguser/client.go:57
MethodDevices
()
client_test.go:235
MethodDevices
Devices implements wginternal.Client.
internal/wguser/client.go:37
MethodDevices
Devices implements wginternal.Client.
internal/wgwindows/client_windows.go:114
MethodDevices
Devices implements wginternal.Client.
internal/wgfreebsd/client_freebsd.go:69
MethodDevices
Devices implements wginternal.Client.
internal/wglinux/client_linux.go:78
MethodString
String returns the string representation of a DeviceType.
wgtypes/types.go:27
FunctionTestBadKeys
(t *testing.T)
wgtypes/types_test.go:55
FunctionTestClientClose
(t *testing.T)
client_test.go:23
FunctionTestClientConfigureDevice
(t *testing.T)
client_test.go:152
FunctionTestClientConfigureDeviceError
(t *testing.T)
internal/wguser/configure_test.go:42
FunctionTestClientConfigureDeviceOK
(t *testing.T)
internal/wguser/configure_test.go:82
FunctionTestClientDevice
(t *testing.T)
client_test.go:69
FunctionTestClientDevice
(t *testing.T)
internal/wguser/client_test.go:18
FunctionTestClientDeviceBasic
(t *testing.T)
internal/wgopenbsd/client_openbsd_test.go:108
FunctionTestClientDeviceNotExist
(t *testing.T)
internal/wgopenbsd/client_openbsd_test.go:265
FunctionTestClientDeviceWrongMemorySize
(t *testing.T)
internal/wgopenbsd/client_openbsd_test.go:295
FunctionTestClientDevices
(t *testing.T)
client_test.go:46
FunctionTestClientDevices
(t *testing.T)
internal/wgopenbsd/client_openbsd_test.go:21
FunctionTestClientDevices
(t *testing.T)
internal/wguser/parse_test.go:44
FunctionTestIntegrationClient
(t *testing.T)
client_integration_test.go:22
FunctionTestIntegrationClientIsNotExist
(t *testing.T)
client_integration_test.go:93
FunctionTestKeyExchange
(t *testing.T)
wgtypes/types_test.go:36
FunctionTestLinuxClientConfigureDevice
(t *testing.T)
internal/wglinux/configure_linux_test.go:22
FunctionTestLinuxClientConfigureDeviceLargePeerIPChunks
(t *testing.T)
internal/wglinux/configure_linux_test.go:275
FunctionTestLinuxClientDevicesEmpty
(t *testing.T)
internal/wglinux/client_linux_test.go:31
FunctionTestLinuxClientDevicesError
(t *testing.T)
internal/wglinux/parse_linux_test.go:23
FunctionTestLinuxClientDevicesOK
(t *testing.T)
internal/wglinux/parse_linux_test.go:99
FunctionTestLinuxClientIsNotExist
(t *testing.T)
internal/wglinux/client_linux_test.go:65
FunctionTestLinuxClientIsPermission
(t *testing.T)
internal/wglinux/client_linux_test.go:130
FunctionTestMarshaling
(t *testing.T)
internal/wgfreebsd/internal/nv/nvlist_test.go:14
FunctionTestPreparedKeys
(t *testing.T)
wgtypes/types_test.go:13
FunctionTestUNIX_findUNIXSockets
(t *testing.T)
internal/wguser/conn_unix_test.go:15
FunctionTest_initClientNotExist
(t *testing.T)
internal/wglinux/client_linux_test.go:155
FunctionTest_parseRTNLInterfaces
(t *testing.T)
internal/wglinux/client_linux_test.go:170
FunctionTest_parseTimespec
(t *testing.T)
internal/wglinux/parse_linux_test.go:494
FunctionTest_timespec32MemoryLayout
(t *testing.T)
internal/wglinux/parse_linux_test.go:570
← previousnext →101–200 of 219, ranked by callers