Replies: 3 comments 1 reply
-
你弄的这么复杂都不如本地弄个优选dns缓存 |
Beta Was this translation helpful? Give feedback.
-
使用 {
"enabled": true,
"destOverride": ["http", "tls", "quic"],
"metadataOnly": false,
"domainsExcluded": [],
"routeOnly": true // 打开
} |
Beta Was this translation helpful? Give feedback.
-
you can try using the "UseIP" mode in Xray's freedom outbound configuration. By specifying the "UseIP" mode and setting the sendThrough field in the outbound connection configuration, Freedom will automatically determine the required IP type (IPv4 or IPv6) based on the value of sendThrough. {
"outbound": {
"protocol": "freedom",
"settings": {
"domainStrategy": "UseIP"
},
"tag": "direct-out"
}
} By using the "UseIP" mode, Xray will resolve the domain name using the built-in DNS server and connect directly to the obtained IP. This should allow you to maintain a direct connection to the IP of the CDN server, even if the domain name is sniffed. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
目前看来行为和文档描述的是一致的:
但是如果我希望即便sniffing出来域名但是走Freedom outbound的时候仍然直连IP,请问有什么办法能办到吗?
之所以有这个需求是因为有一些在CDN后面的网站我希望保持延迟尽可能低,所以本地写了个脚本用来检测哪个CDN服务器的延迟最低,然后直连CDN服务器的IP并且手动指定sni(例如直接修改hosts文件)。但是因为xray/v2ray的freedom outbound的这个行为,只要tls连接里嗅探出来了sni,目标IP就会被重置成本地dns的解析结果。但是sni又是不能被省略的,否则CDN反代就不能成功。
Beta Was this translation helpful? Give feedback.
All reactions