From 30c069f5b714a9a79049dbc488e6634ee726e810 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=B8=96=E7=95=8C?= Date: Tue, 2 Sep 2025 17:34:38 +0800 Subject: [PATCH] Fix local DNS server on legacy windows --- dns/transport_dialer.go | 1 + go.mod | 2 +- go.sum | 6 ++++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/dns/transport_dialer.go b/dns/transport_dialer.go index b3ee8082..2ed70ead 100644 --- a/dns/transport_dialer.go +++ b/dns/transport_dialer.go @@ -19,6 +19,7 @@ func NewLocalDialer(ctx context.Context, options option.LocalDNSServerOptions) ( if options.LegacyDefaultDialer { return dialer.NewDefaultOutbound(ctx), nil } else { + options.UDPFragmentDefault = true return dialer.NewWithOptions(dialer.Options{ Context: ctx, Options: options.DialerOptions, diff --git a/go.mod b/go.mod index ce6ebdc8..6f18a013 100644 --- a/go.mod +++ b/go.mod @@ -27,7 +27,7 @@ require ( github.com/sagernet/gomobile v0.1.8 github.com/sagernet/gvisor v0.0.0-20250325023245-7a9c0f5725fb github.com/sagernet/quic-go v0.52.0-beta.1 - github.com/sagernet/sing v0.7.6-0.20250825114712-2aeec120ce28 + github.com/sagernet/sing v0.7.6 github.com/sagernet/sing-mux v0.3.3 github.com/sagernet/sing-quic v0.5.0 github.com/sagernet/sing-shadowsocks v0.2.8 diff --git a/go.sum b/go.sum index c359cc2e..750d2310 100644 --- a/go.sum +++ b/go.sum @@ -167,8 +167,10 @@ github.com/sagernet/nftables v0.3.0-beta.4/go.mod h1:OQXAjvjNGGFxaTgVCSTRIhYB5/l github.com/sagernet/quic-go v0.52.0-beta.1 h1:hWkojLg64zjV+MJOvJU/kOeWndm3tiEfBLx5foisszs= github.com/sagernet/quic-go v0.52.0-beta.1/go.mod h1:OV+V5kEBb8kJS7k29MzDu6oj9GyMc7HA07sE1tedxz4= github.com/sagernet/sing v0.6.9/go.mod h1:ARkL0gM13/Iv5VCZmci/NuoOlePoIsW0m7BWfln/Hak= -github.com/sagernet/sing v0.7.6-0.20250825114712-2aeec120ce28 h1:C8Lnqd0Q+C15kwaMiDsfq5S45rhhaQMBG91TT+6oFVo= -github.com/sagernet/sing v0.7.6-0.20250825114712-2aeec120ce28/go.mod h1:ARkL0gM13/Iv5VCZmci/NuoOlePoIsW0m7BWfln/Hak= +github.com/sagernet/sing v0.7.6-0.20250902093152-bd5790e3b4db h1:D+56hVUg42b+nbXVYMwDNyFaN6vTviSXqF96dvBqRiM= +github.com/sagernet/sing v0.7.6-0.20250902093152-bd5790e3b4db/go.mod h1:ARkL0gM13/Iv5VCZmci/NuoOlePoIsW0m7BWfln/Hak= +github.com/sagernet/sing v0.7.6 h1:6LBfDH+aI/26J3r9UHlaxTNjJeMhBpU/wrk0JKDZYI4= +github.com/sagernet/sing v0.7.6/go.mod h1:ARkL0gM13/Iv5VCZmci/NuoOlePoIsW0m7BWfln/Hak= github.com/sagernet/sing-mux v0.3.3 h1:YFgt9plMWzH994BMZLmyKL37PdIVaIilwP0Jg+EcLfw= github.com/sagernet/sing-mux v0.3.3/go.mod h1:pht8iFY4c9Xltj7rhVd208npkNaeCxzyXCgulDPLUDA= github.com/sagernet/sing-quic v0.5.0 h1:jNLIyVk24lFPvu8A4x+ZNEnZdI+Tg1rp7eCJ6v0Csak=