macronut / phantomsocks

A cross-platform proxy client/server for Linux/Windows/macOS
GNU Lesser General Public License v3.0
453 stars 18 forks source link

rules 文件中配置的域名 ip 不起作用 #54

Closed LinHQ1999 closed 1 year ago

LinHQ1999 commented 1 year ago

在配置的过程中又遇到了一个问题,google.com 已经配置了 ip 地址,但实际上却没有通过这些 ip 进行访问。

[default]
# ...
[google]
google.com=142.250.12.90,142.250.128.90,142.250.1.90,142.250.103.90,142.251.15.90,142.250.125.90,142.250.11.90,142.250.111.90,142.250.98.90,142.251.0.90
.googleapis.com=[google.com]
.google.com=[google.com]
google.com.hk=[google.com]
.google.com.tw=[google.com]
.googleusercontent.com=[google.com]
.ytimg.com=[google.com]
.youtube.com=[google.com]
youtube.com=[google.com]
.youtube-nocookie.com=[google.com]
youtu.be=[google.com]
.ggpht.com=[google.com]
.gstatic.com=[google.com]
.translate.goog=[google.com]
blogspot.com=[google.com]
.blogspot.com=[google.com]
sniproxy=178.209.51.200,78.129.226.113,31.200.241.28
dns.google=[sniproxy]
.googlevideo.com=[sniproxy]
translate.googleapis.com=[google.com]
.chrome.com=[google.com]
{
  "profiles": ["default.conf"],
  "services": [
    {
      "name": "DNS",
      "protocol": "dns",
      "address": "127.0.0.1:53"
    },
    {
      "name": "socks",
      "protocol": "socks",
      "address": "127.0.0.1:9999"
    }
  ],
  "interfaces": [
    {
      "name": "default",
      "dns": "tls://120.53.53.53:853"
    },
    {
      "name": "google",
      "dns": "https://45.11.45.11/dns-query",
      "hint": "w-md5,w-seq,https"
    }
  ]
}

日志:

image

NVEI7A 983}9A_$8V{UCOPS

ghost commented 1 year ago

因为你的配置文件根本没有指定 www.google.com.hk 使用你设置的IP。你的 default.conf 中只有 google.com.hk=[google.com] 而没有 .google.com.hk=[google.com]


另外 157.240.20.8 这种很明显是GFW丢给你的污染IP,建议还是不要用 DNSPod 的 DoT tls://120.53.53.53:853

LinHQ1999 commented 1 year ago

感谢老哥的建议,问题已经解决,确实加上 .google.com.hk 就好了,看来和 GhosTCP 的规则还是有一点不一样。