github.com/kelleygo/clashcore@v1.0.2/constant/ebpf.go (about) 1 package constant 2 3 import ( 4 "net/netip" 5 6 "github.com/kelleygo/clashcore/transport/socks5" 7 ) 8 9 const ( 10 BpfFSPath = "/sys/fs/bpf/yiclashcore" 11 12 TcpAutoRedirPort = 't'<<8 | 'r'<<0 13 YiClashCoreTrafficMark = 'c'<<24 | 'l'<<16 | 't'<<8 | 'm'<<0 14 ) 15 16 type EBpf interface { 17 Start() error 18 Close() 19 Lookup(srcAddrPort netip.AddrPort) (socks5.Addr, error) 20 }