chore: support TFO for outbounds

This commit is contained in:
wwqgtxx
2023-02-24 13:53:44 +08:00
parent 75680c5866
commit 7d524668e0
12 changed files with 144 additions and 1 deletions

View File

@@ -18,6 +18,7 @@ type option struct {
routingMark int
network int
prefer int
tfo bool
resolver resolver.Resolver
}
@@ -69,6 +70,12 @@ func WithOnlySingleStack(isIPv4 bool) Option {
}
}
func WithTFO(tfo bool) Option {
return func(opt *option) {
opt.tfo = tfo
}
}
func WithOption(o option) Option {
return func(opt *option) {
*opt = o