mnet_core_udp

package
v0.0.0-...-4adfca9 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 2, 2020 License: AGPL-3.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type UDPTransport

type UDPTransport struct{}

func GetUDPTransport

func GetUDPTransport() *UDPTransport

func (*UDPTransport) Listen

func (udpt *UDPTransport) Listen(physConn *net.UDPConn, tapConn *mnet_if.Interface, peerAddr *net.UDPAddr, key []byte,
	dataKey *[]byte, isSecure bool, peerDiscoveryChannel chan net.UDPAddr, isTun bool, signalChannel chan string)

To forward data from physical interface to tap/tun/virtual link interface

func (*UDPTransport) ListenAndTransmit

func (udpt *UDPTransport) ListenAndTransmit(
	localIpAddr string, localPort string,
	remoteIpAddr string, remotePort string,
	tapConn *mnet_if.Interface,
	key []byte, dataKey *[]byte,
	isSecure bool, isTun bool,
	listenSignalChannel chan string, transmitSignalChannel chan string) (net.Conn, error)

func (*UDPTransport) Transmit

func (udpt *UDPTransport) Transmit(physConn *net.UDPConn, tapConn *mnet_if.Interface, peerAddr *net.UDPAddr, key []byte, dataKey *[]byte,
	isSecure bool, peerDiscoveryChannel chan net.UDPAddr, isTun bool, signalChannel chan string)

To forward data from tap/tun/virtual link interface to physical interface

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL