mihomo/constant/tunnel.go

13 lines
327 B
Go
Raw Normal View History

package constant
2023-10-11 10:55:12 +08:00
import "net"
type Tunnel interface {
// HandleTCPConn will handle a tcp connection blocking
2023-10-11 10:55:12 +08:00
HandleTCPConn(conn net.Conn, metadata *Metadata)
// HandleUDPPacket will handle a udp packet nonblocking
2023-10-11 10:55:12 +08:00
HandleUDPPacket(packet UDPPacket, metadata *Metadata)
// NatTable return nat table
NatTable() NatTable
}