mirror of
https://github.com/openp2p-cn/openp2p.git
synced 2025-10-28 10:32:48 +08:00
3.18.4 virtual private network
This commit is contained in:
20
core/optun.go
Normal file
20
core/optun.go
Normal file
@@ -0,0 +1,20 @@
|
||||
package openp2p
|
||||
|
||||
import (
|
||||
"github.com/openp2p-cn/wireguard-go/tun"
|
||||
)
|
||||
|
||||
var AndroidSDWANConfig chan []byte
|
||||
|
||||
type optun struct {
|
||||
tunName string
|
||||
dev tun.Device
|
||||
}
|
||||
|
||||
func (t *optun) Stop() error {
|
||||
t.dev.Close()
|
||||
return nil
|
||||
}
|
||||
func init() {
|
||||
AndroidSDWANConfig = make(chan []byte, 1)
|
||||
}
|
||||
Reference in New Issue
Block a user