Skip to content

Commit

Permalink
Add tun stack option
Browse files Browse the repository at this point in the history
  • Loading branch information
problematicconsumer committed Sep 5, 2023
1 parent 611f295 commit e38dfdf
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions shared/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ type ConfigOptions struct {
MixedPort uint16 `json:"mixed-port"`
LocalDnsPort uint16 `json:"local-dns-port"`
MTU uint32 `json:"mtu"`
TUNStack string `json:"tun-stack"`
ConnectionTestUrl string `json:"connection-test-url"`
URLTestInterval option.Duration `json:"url-test-interval"`
EnableClashApi bool `json:"enable-clash-api"`
Expand Down Expand Up @@ -129,6 +130,7 @@ func BuildConfig(configOpt ConfigOptions, input option.Options) option.Options {
Type: C.TypeTun,
Tag: "tun-in",
TunOptions: option.TunInboundOptions{
Stack: configOpt.TUNStack,
MTU: configOpt.MTU,
AutoRoute: true,
StrictRoute: true,
Expand Down

0 comments on commit e38dfdf

Please sign in to comment.