mirror of
https://github.com/netbirdio/netbird.git
synced 2024-12-12 18:00:49 +01:00
a7d6632298
* Adds management, signal, and relay (STUN/TURN) health probes to the status command. * Adds a reason when the management or signal connections are disconnected. * Adds last wireguard handshake and received/sent bytes per peer
19 lines
500 B
Go
19 lines
500 B
Go
package iface
|
|
|
|
import (
|
|
"net"
|
|
"time"
|
|
|
|
"golang.zx2c4.com/wireguard/wgctrl/wgtypes"
|
|
)
|
|
|
|
type wgConfigurer interface {
|
|
configureInterface(privateKey string, port int) error
|
|
updatePeer(peerKey string, allowedIps string, keepAlive time.Duration, endpoint *net.UDPAddr, preSharedKey *wgtypes.Key) error
|
|
removePeer(peerKey string) error
|
|
addAllowedIP(peerKey string, allowedIP string) error
|
|
removeAllowedIP(peerKey string, allowedIP string) error
|
|
close()
|
|
getStats(peerKey string) (WGStats, error)
|
|
}
|