Refactor: optimize UDP module

Symmetric NAT support for now.
This commit is contained in:
xjasonlyu
2022-02-05 15:49:03 +08:00
parent 14c663c40e
commit dd0cde04b4
10 changed files with 124 additions and 386 deletions

View File

@@ -1,6 +1,8 @@
package core
// Handler is a TCP/UDP connection handler that implements
// HandleTCPConn and HandleUDPConn methods.
type Handler interface {
Add(TCPConn)
AddPacket(UDPPacket)
HandleTCPConn(TCPConn)
HandleUDPConn(UDPConn)
}