From 0616e92c257d61207036b5533f8a7748236c71e8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=A3=8E=E6=89=87=E6=BB=91=E7=BF=94=E7=BF=BC?= Date: Thu, 15 May 2025 07:16:46 +0000 Subject: [PATCH] Sniff: Fix fakedns+others --- app/dispatcher/default.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/dispatcher/default.go b/app/dispatcher/default.go index 54864cbb..408301de 100644 --- a/app/dispatcher/default.go +++ b/app/dispatcher/default.go @@ -226,8 +226,8 @@ func (d *DefaultDispatcher) shouldOverride(ctx context.Context, result SniffResu if strings.HasPrefix(protocolString, p) || strings.HasPrefix(p, protocolString) { return true } - if fkr0, ok := d.fdns.(dns.FakeDNSEngineRev0); ok && protocolString != "bittorrent" && p == "fakedns" && - fkr0.IsIPInIPPool(destination.Address) { + if fkr0, ok := d.fdns.(dns.FakeDNSEngineRev0); ok && protocolString != "bittorrent" && strings.HasPrefix(p, "fakedns") && + (fkr0.IsIPInIPPool(destination.Address) || p == "fakedns+others") { errors.LogInfo(ctx, "Using sniffer ", protocolString, " since the fake DNS missed") return true }