From 5c8b283d9cd84a4b1412dd65572ae039a822de78 Mon Sep 17 00:00:00 2001 From: problematicconsumer Date: Sat, 11 Nov 2023 23:06:23 +0330 Subject: [PATCH] Add strict route option --- shared/config.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/shared/config.go b/shared/config.go index cb2ac65..e3f80d6 100644 --- a/shared/config.go +++ b/shared/config.go @@ -25,6 +25,7 @@ type ConfigOptions struct { MixedPort uint16 `json:"mixed-port"` LocalDnsPort uint16 `json:"local-dns-port"` MTU uint32 `json:"mtu"` + StrictRoute bool `json:"strict-route"` TUNStack string `json:"tun-stack"` ConnectionTestUrl string `json:"connection-test-url"` URLTestInterval option.Duration `json:"url-test-interval"` @@ -112,7 +113,7 @@ func BuildConfig(configOpt ConfigOptions, input option.Options) option.Options { Stack: configOpt.TUNStack, MTU: configOpt.MTU, AutoRoute: true, - StrictRoute: true, + StrictRoute: configOpt.StrictRoute, EndpointIndependentNat: true, InboundOptions: option.InboundOptions{ SniffEnabled: true,