mirror of
https://github.com/SagerNet/sing-tun.git
synced 2025-04-04 04:17:39 +03:00
Migrate to udpnat2 / Add PrepareConnection
This commit is contained in:
parent
99eea00432
commit
7f8e556bb0
6 changed files with 121 additions and 84 deletions
2
tun.go
2
tun.go
|
@ -10,11 +10,13 @@ import (
|
|||
|
||||
F "github.com/sagernet/sing/common/format"
|
||||
"github.com/sagernet/sing/common/logger"
|
||||
M "github.com/sagernet/sing/common/metadata"
|
||||
N "github.com/sagernet/sing/common/network"
|
||||
"github.com/sagernet/sing/common/ranges"
|
||||
)
|
||||
|
||||
type Handler interface {
|
||||
PrepareConnection(source M.Socksaddr, destination M.Socksaddr) error
|
||||
N.TCPConnectionHandlerEx
|
||||
N.UDPConnectionHandlerEx
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue