snail007 / goproxy

🔥 Proxy is a high performance HTTP(S) proxies, SOCKS5 proxies,WEBSOCKET, TCP, UDP proxy server implemented by golang. Now, it supports chain-style proxies,nat forwarding in different lan,TCP/UDP port forwarding, SSH forwarding.Proxy是golang实现的高性能http,https,websocket,tcp,socks5代理服务器,支持内网穿透,链式代理,通讯加密,智能HTTP,SOCKS5代理,黑白名单,限速,限流量,限连接数,跨平台,KCP支持,认证API。
https://snail007.host900.com/goproxy/manual/zh/
GNU General Public License v3.0
15.87k stars 3.01k forks source link

无法解析IPV6地址,访问异常 #544

Open kimoziiiii opened 1 year ago

kimoziiiii commented 1 year ago

Expected Behavior

这是个BUG!钉钉试用免费/商业版本代理访问异常

Current Behavior

image

Possible Solution

看日志,应该是无法识别DNS返回的IPv6地址

2023/11/01 07:17:44.678 WARN connect fail, target: www.dingtalk.com:80([[2401:b180:2000:50::b]:443]:80), parent: , err: dial tcp: address [[2401:b180:2000:50::b]:443]:80: too many colons in address

Steps to Reproduce

  1. proxy http -p :10808 --dns-address 10.0.20.194 --dns-ttl 600 --bind-ip 10.0.20.202:10808
  2. image

Context (Environment)

  1. proxy version is : commercial_14.0
  2. full command is : proxy http -p :10808 --dns-address 10.0.20.194 --dns-ttl 600 --bind-ip 10.0.20.202:10808
  3. system is : Ubuntu22.04LTS
  4. full log is:

Detailed Description

Possible Implementation

snail007 commented 1 year ago

这你的dns问题,返回了的IP地址里面包含了端口号,这是错误的行为。

kimoziiiii commented 1 year ago

DNS我用的是dnsmasq,只是用来做转发,上级DNS是直接递归到公网DNS了,DNS返回的结果里面不应该带端口啊,dnsmasq我没有做任何的自定义修改。