SagerNet / SagerNet/sing-box

DNS local doesn't work properly on macOS

Open
#3,359 9 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Go
Stars
38.1k
Forks
4.6k
Avg merge
19d 15h
Merged PRs (30d)
1

Description

Operating system

macOS

System version

Tahoe 26.0 beta

Installation type

sing-box for macOS Graphical Client

If you are using a graphical client, please provide the version of the client.

1.13.0-alpha.8 (1)

Version

Description

Local DNS seems to not properly work on macOS.
The local servers could not be fetched by sing-box core (context cancelled) for some reason, and that's why local server is unusable.

Reproduction

Using the following simple config

{
  "log": {
    "level": "debug",
    "timestamp": true
  },
  "dns": {
    "servers": [
      {
        "tag": "dns-direct",
        "type": "local"
      }
    ],
    "strategy": "ipv4_only",
    "reverse_mapping": true,
    "final": "dns-direct"
  },
  "inbounds": [
    {
      "type": "tun",
      "tag": "in-tun",
      "address": "172.16.0.1/30",
      "mtu": 1492,
      "auto_route": true,
      "strict_route": false,
      "sniff": true
    }
  ],
  "outbounds": [
    {
      "tag": "direct",
      "type": "direct"
    }
  ],
  "route": {
    "rules": [
      {
        "protocol": "dns",
        "action": "hijack-dns"
      },
      {
        "action": "route",
        "outbound": "direct"
      }
    ],
    "auto_detect_interface": true
  }
}

the DNS stops working.

I believe the connection timeout appears:

+0300 2025-09-05 21:08:10 INFO dns/local[dns-direct]: dhcp: query DNS servers on en0
...
+0300 2025-09-05 21:08:31 ERROR dns/local[dns-direct]: fetch DNS servers: context canceled

At the same time, I can easily resolve directly like

> host google.com
;; connection timed out; no servers could be reached

> host google.com 192.168.0.1 (my DHCP server)
google.com has address 173.194.222.139
google.com has address 173.194.222.101
google.com has address 173.194.222.138
google.com has address 173.194.222.113
google.com has address 173.194.222.100
google.com has address 173.194.222.102
google.com mail is handled by 10 smtp.google.com.
Logs
Full logs:

+0300 2025-09-05 21:08:10 INFO network: updated available networks: en0 (wifi), en0 (wifi)
+0300 2025-09-05 21:08:10 INFO network: updated default interface en0, index 14, type wifi
+0300 2025-09-05 21:08:10 INFO dns/local[dns-direct]: dhcp: query DNS servers on en0
+0300 2025-09-05 21:08:11 INFO inbound/tun[in-tun]: started at utun4
+0300 2025-09-05 21:08:11 INFO sing-box started (0.99s)
+0300 2025-09-05 21:08:11 INFO [637112263 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:51815
+0300 2025-09-05 21:08:11 INFO [637112263 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 INFO [2402777454 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:52718
+0300 2025-09-05 21:08:11 INFO [2402777454 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 DEBUG [637112263 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [637112263 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [637112263 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [2402777454 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [2402777454 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [2402777454 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [2402777454 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [2402777454 0ms] dns: exchange lb._dns-sd._udp.0.0.168.192.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:11 DEBUG [637112263 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [637112263 0ms] dns: exchange lb._dns-sd._udp.lan. IN PTR
+0300 2025-09-05 21:08:11 INFO [746575181 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:52156
+0300 2025-09-05 21:08:11 INFO [4189651234 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:58569
+0300 2025-09-05 21:08:11 INFO [2850816963 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:63362
+0300 2025-09-05 21:08:11 INFO [746575181 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 INFO [2850816963 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 INFO [3885291389 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:61313
+0300 2025-09-05 21:08:11 INFO [3885291389 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 DEBUG [746575181 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [2850816963 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [2850816963 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 INFO [2997365419 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:50952
+0300 2025-09-05 21:08:11 DEBUG [746575181 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 INFO [4189651234 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 INFO [2169857770 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:62617
+0300 2025-09-05 21:08:11 DEBUG [4189651234 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 INFO [2169857770 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 INFO [3855883086 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:65001
+0300 2025-09-05 21:08:11 DEBUG [2169857770 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [2169857770 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 INFO [2997365419 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 DEBUG [4189651234 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 INFO [1167653047 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:49982
+0300 2025-09-05 21:08:11 INFO [3855883086 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 DEBUG [3855883086 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 INFO [1167653047 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 INFO [1082223093 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:51240
+0300 2025-09-05 21:08:11 DEBUG [1167653047 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [1167653047 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [2169857770 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [3855883086 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [3855883086 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [746575181 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [4189651234 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [1167653047 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [4189651234 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [2997365419 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [2169857770 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [2997365419 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [2997365419 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [2997365419 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [4189651234 1ms] dns: exchange 1-courier.sandbox.push.apple.com. IN A
+0300 2025-09-05 21:08:11 DEBUG [2169857770 0ms] dns: exchange 1.0.16.172.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:11 DEBUG [2997365419 0ms] dns: exchange 1-courier.push.apple.com. IN A
+0300 2025-09-05 21:08:11 DEBUG [746575181 1ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 INFO [1082223093 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 DEBUG [746575181 1ms] dns: exchange apple.com. IN A
+0300 2025-09-05 21:08:11 DEBUG [2850816963 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [3855883086 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [2850816963 1ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [3855883086 0ms] dns: exchange _dns.resolver.arpa. IN SVCB
+0300 2025-09-05 21:08:11 DEBUG [2850816963 1ms] dns: exchange lb._dns-sd._udp.0.0.16.172.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:11 DEBUG [3885291389 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [1082223093 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [3885291389 1ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [1082223093 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [1167653047 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [3885291389 1ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [3885291389 1ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [1082223093 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [1167653047 0ms] dns: exchange www.apple.com. IN A
+0300 2025-09-05 21:08:11 DEBUG [1082223093 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [3885291389 1ms] dns: exchange api.apple-cloudkit.com. IN A
+0300 2025-09-05 21:08:11 DEBUG [1082223093 0ms] dns: exchange 111.0.168.192.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:11 INFO [3913917956 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:65182
+0300 2025-09-05 21:08:11 INFO [3913917956 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 DEBUG [3913917956 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [3913917956 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [3913917956 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [3913917956 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [3913917956 0ms] dns: exchange gateway.icloud.com. IN A
+0300 2025-09-05 21:08:11 INFO [8213068 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:52415
+0300 2025-09-05 21:08:11 INFO [2134196102 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:63209
+0300 2025-09-05 21:08:11 INFO [8213068 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 INFO [2134196102 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 DEBUG [2134196102 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [8213068 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [2134196102 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [8213068 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [2134196102 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [8213068 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [2134196102 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [8213068 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [2134196102 0ms] dns: exchange kt-prod.ess.apple.com. IN A
+0300 2025-09-05 21:08:11 DEBUG [8213068 0ms] dns: exchange kt-prod.ess.apple.com. IN HTTPS
+0300 2025-09-05 21:08:11 INFO [2592371234 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:59920
+0300 2025-09-05 21:08:11 INFO [2592371234 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 DEBUG [2592371234 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [2592371234 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [2592371234 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [2592371234 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [2592371234 0ms] dns: exchange 18-courier.push.apple.com. IN A
+0300 2025-09-05 21:08:11 INFO [319804302 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:55959
+0300 2025-09-05 21:08:11 INFO [319804302 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:11 DEBUG [319804302 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:11 DEBUG [319804302 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:11 DEBUG [319804302 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:11 DEBUG [319804302 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:11 DEBUG [319804302 0ms] dns: exchange sync-v2.brave.com. IN A
+0300 2025-09-05 21:08:12 DEBUG [2402777454 1.2s] dns: exchange lb._dns-sd._udp.0.0.168.192.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:12 DEBUG [2850816963 1.2s] dns: exchange lb._dns-sd._udp.0.0.16.172.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:12 DEBUG [1082223093 1.2s] dns: exchange 111.0.168.192.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:12 DEBUG [2169857770 1.2s] dns: exchange 1.0.16.172.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:12 DEBUG [637112263 1.2s] dns: exchange lb._dns-sd._udp.lan. IN PTR
+0300 2025-09-05 21:08:12 DEBUG [746575181 1.2s] dns: exchange apple.com. IN A
+0300 2025-09-05 21:08:12 DEBUG [1167653047 1.2s] dns: exchange www.apple.com. IN A
+0300 2025-09-05 21:08:12 DEBUG [3885291389 1.2s] dns: exchange api.apple-cloudkit.com. IN A
+0300 2025-09-05 21:08:12 DEBUG [3855883086 1.2s] dns: exchange _dns.resolver.arpa. IN SVCB
+0300 2025-09-05 21:08:12 DEBUG [2997365419 1.2s] dns: exchange 1-courier.push.apple.com. IN A
+0300 2025-09-05 21:08:12 DEBUG [4189651234 1.2s] dns: exchange 1-courier.sandbox.push.apple.com. IN A
+0300 2025-09-05 21:08:12 DEBUG [3913917956 1.0s] dns: exchange gateway.icloud.com. IN A
+0300 2025-09-05 21:08:12 DEBUG [8213068 1.0s] dns: exchange kt-prod.ess.apple.com. IN HTTPS
+0300 2025-09-05 21:08:12 DEBUG [2134196102 1.0s] dns: exchange kt-prod.ess.apple.com. IN A
+0300 2025-09-05 21:08:12 DEBUG [2592371234 1.0s] dns: exchange 18-courier.push.apple.com. IN A
+0300 2025-09-05 21:08:12 DEBUG [319804302 1.2s] dns: exchange sync-v2.brave.com. IN A
+0300 2025-09-05 21:08:13 INFO [3003259403 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:49346
+0300 2025-09-05 21:08:13 INFO [3003259403 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:13 DEBUG [3003259403 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:13 DEBUG [3003259403 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:13 DEBUG [3003259403 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:13 DEBUG [3003259403 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:13 DEBUG [3003259403 0ms] dns: exchange www.youtube.com. IN A
+0300 2025-09-05 21:08:14 INFO [2111645478 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:62151
+0300 2025-09-05 21:08:14 DEBUG [2402777454 3.5s] dns: exchange lb._dns-sd._udp.0.0.168.192.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:14 DEBUG [637112263 3.5s] dns: exchange lb._dns-sd._udp.lan. IN PTR
+0300 2025-09-05 21:08:14 DEBUG [1082223093 3.5s] dns: exchange 111.0.168.192.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:14 DEBUG [746575181 3.5s] dns: exchange apple.com. IN A
+0300 2025-09-05 21:08:14 INFO [2111645478 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:14 DEBUG [2169857770 3.5s] dns: exchange 1.0.16.172.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:14 DEBUG [2850816963 3.5s] dns: exchange lb._dns-sd._udp.0.0.16.172.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:14 DEBUG [1167653047 3.5s] dns: exchange www.apple.com. IN A
+0300 2025-09-05 21:08:14 DEBUG [2111645478 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:14 DEBUG [3885291389 3.5s] dns: exchange api.apple-cloudkit.com. IN A
+0300 2025-09-05 21:08:14 DEBUG [2111645478 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:14 DEBUG [2111645478 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:14 DEBUG [2111645478 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:14 DEBUG [3855883086 3.5s] dns: exchange _dns.resolver.arpa. IN SVCB
+0300 2025-09-05 21:08:14 DEBUG [2997365419 3.5s] dns: exchange 1-courier.push.apple.com. IN A
+0300 2025-09-05 21:08:14 DEBUG [2111645478 0ms] dns: exchange clerk.openrouter.ai. IN A
+0300 2025-09-05 21:08:14 DEBUG [4189651234 3.5s] dns: exchange 1-courier.sandbox.push.apple.com. IN A
+0300 2025-09-05 21:08:14 DEBUG [3913917956 3.4s] dns: exchange gateway.icloud.com. IN A
+0300 2025-09-05 21:08:14 DEBUG [8213068 3.3s] dns: exchange kt-prod.ess.apple.com. IN HTTPS
+0300 2025-09-05 21:08:14 DEBUG [2134196102 3.3s] dns: exchange kt-prod.ess.apple.com. IN A
+0300 2025-09-05 21:08:14 DEBUG [2592371234 3.3s] dns: exchange 18-courier.push.apple.com. IN A
+0300 2025-09-05 21:08:14 DEBUG [319804302 3.12s] dns: exchange sync-v2.brave.com. IN A
+0300 2025-09-05 21:08:14 DEBUG [3003259403 1.5s] dns: exchange www.youtube.com. IN A
+0300 2025-09-05 21:08:15 INFO [3135427908 0ms] inbound/tun[in-tun]: inbound packet connection from 172.16.0.1:55345
+0300 2025-09-05 21:08:15 INFO [3135427908 0ms] inbound/tun[in-tun]: inbound packet connection to 172.16.0.2:53
+0300 2025-09-05 21:08:15 DEBUG [3135427908 0ms] router: sniffed packet protocol: dns
+0300 2025-09-05 21:08:15 DEBUG [3135427908 0ms] router: match[0] => sniff
+0300 2025-09-05 21:08:15 DEBUG [3135427908 0ms] router: duplicate sniff skipped
+0300 2025-09-05 21:08:15 DEBUG [3135427908 0ms] router: match[1] protocol=dns => hijack-dns
+0300 2025-09-05 21:08:15 DEBUG [3135427908 0ms] dns: exchange example.com. IN A
+0300 2025-09-05 21:08:15 DEBUG [2111645478 1.2s] dns: exchange clerk.openrouter.ai. IN A
+0300 2025-09-05 21:08:16 DEBUG [3003259403 3.15s] dns: exchange www.youtube.com. IN A
+0300 2025-09-05 21:08:17 DEBUG [2111645478 3.2s] dns: exchange clerk.openrouter.ai. IN A
+0300 2025-09-05 21:08:18 DEBUG [2402777454 7.8s] dns: exchange lb._dns-sd._udp.0.0.168.192.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:18 DEBUG [746575181 7.8s] dns: exchange apple.com. IN A
+0300 2025-09-05 21:08:18 DEBUG [2169857770 7.8s] dns: exchange 1.0.16.172.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:18 DEBUG [3885291389 7.8s] dns: exchange api.apple-cloudkit.com. IN A
+0300 2025-09-05 21:08:18 DEBUG [1167653047 7.8s] dns: exchange www.apple.com. IN A
+0300 2025-09-05 21:08:18 DEBUG [2850816963 7.8s] dns: exchange lb._dns-sd._udp.0.0.16.172.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:18 DEBUG [3855883086 7.8s] dns: exchange _dns.resolver.arpa. IN SVCB
+0300 2025-09-05 21:08:18 DEBUG [2997365419 7.8s] dns: exchange 1-courier.push.apple.com. IN A
+0300 2025-09-05 21:08:18 DEBUG [3913917956 7.6s] dns: exchange gateway.icloud.com. IN A
+0300 2025-09-05 21:08:18 DEBUG [4189651234 7.8s] dns: exchange 1-courier.sandbox.push.apple.com. IN A
+0300 2025-09-05 21:08:18 DEBUG [2592371234 7.6s] dns: exchange 18-courier.push.apple.com. IN A
+0300 2025-09-05 21:08:18 DEBUG [319804302 7.31s] dns: exchange sync-v2.brave.com. IN A
+0300 2025-09-05 21:08:20 DEBUG [3135427908 5.0s] dns: exchange example.com. IN A
+0300 2025-09-05 21:08:20 DEBUG [3003259403 7.28s] dns: exchange www.youtube.com. IN A
+0300 2025-09-05 21:08:21 DEBUG [2111645478 7.22s] dns: exchange clerk.openrouter.ai. IN A
+0300 2025-09-05 21:08:26 DEBUG [2402777454 15.12s] dns: exchange lb._dns-sd._udp.0.0.168.192.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:26 DEBUG [1167653047 15.12s] dns: exchange www.apple.com. IN A
+0300 2025-09-05 21:08:26 DEBUG [2997365419 15.12s] dns: exchange 1-courier.push.apple.com. IN A
+0300 2025-09-05 21:08:26 DEBUG [4189651234 15.12s] dns: exchange 1-courier.sandbox.push.apple.com. IN A
+0300 2025-09-05 21:08:26 DEBUG [3885291389 15.12s] dns: exchange api.apple-cloudkit.com. IN A
+0300 2025-09-05 21:08:26 DEBUG [2850816963 15.12s] dns: exchange lb._dns-sd._udp.0.0.16.172.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:26 DEBUG [746575181 15.12s] dns: exchange apple.com. IN A
+0300 2025-09-05 21:08:26 DEBUG [2169857770 15.12s] dns: exchange 1.0.16.172.in-addr.arpa. IN PTR
+0300 2025-09-05 21:08:26 DEBUG [3913917956 15.11s] dns: exchange gateway.icloud.com. IN A
+0300 2025-09-05 21:08:26 DEBUG [2592371234 15.11s] dns: exchange 18-courier.push.apple.com. IN A
+0300 2025-09-05 21:08:26 DEBUG [319804302 15.67s] dns: exchange sync-v2.brave.com. IN A
+0300 2025-09-05 21:08:29 DEBUG [3003259403 15.53s] dns: exchange www.youtube.com. IN A
+0300 2025-09-05 21:08:29 DEBUG [2111645478 15.61s] dns: exchange clerk.openrouter.ai. IN A
+0300 2025-09-05 21:08:31 ERROR dns/local[dns-direct]: fetch DNS servers: context canceled
+0300 2025-09-05 21:08:31 INFO dns/local[dns-direct]: dhcp: query DNS servers on en0
Supporter
Integrity requirements
  • I confirm that I have read the documentation, understand the meaning of all the configuration items I wrote, and did not pile up seemingly useful options or default values.
  • I confirm that I have provided the server and client configuration files and process that can be reproduced locally, instead of a complicated client configuration file that has been stripped of sensitive data.
  • I confirm that I have provided the simplest configuration that can be used to reproduce the error I reported, instead of depending on remote servers, TUN, graphical interface clients, or other closed-source software.
  • I confirm that I have provided the complete configuration files and logs, rather than just providing parts I think are useful out of confidence in my own intelligence.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the local DNS server path and the provided macOS configuration, then reproduce the failure with the sing-box graphical client on macOS Tahoe. Use the debug logs to trace the DHCP DNS query on en0 and the resulting context cancellation; done means the local server fetches the DHCP DNS server and DNS resolution succeeds.

Written by the indexing model from the issue text.

Assessment

Tech stack
go, macos
Domain
networking
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Active
Clarity
Needs clarification
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.