fix: 修改样式
This commit is contained in:
@@ -607,6 +607,15 @@ class KRSingBoxImp {
|
||||
KRLogUtil.kr_i('✅ [智能代理模式] region 设为 $effectiveRegion', tag: 'SingBox');
|
||||
}
|
||||
|
||||
final useWindowsDnsDefaults = Platform.isWindows;
|
||||
final remoteDnsAddress = useWindowsDnsDefaults
|
||||
? 'udp://1.1.1.1'
|
||||
: 'https://dns.google/dns-query';
|
||||
final directDnsAddress = useWindowsDnsDefaults
|
||||
? (effectiveRegion == 'cn' ? 'udp://223.5.5.5' : 'udp://1.1.1.1')
|
||||
: 'local';
|
||||
final dnsDomainStrategy = useWindowsDnsDefaults ? '' : 'prefer_ipv4';
|
||||
|
||||
final op = {
|
||||
"region": effectiveRegion, // 🔧 修复:根据出站模式动态设置 region
|
||||
"block-ads": false, // 参考 hiddify-app: 默认关闭广告拦截
|
||||
@@ -616,11 +625,10 @@ class KRSingBoxImp {
|
||||
"resolve-destination": false,
|
||||
"ipv6-mode":
|
||||
"ipv4_only", // 参考 hiddify-app: 仅使用 IPv4 (有效值: ipv4_only, prefer_ipv4, prefer_ipv6, ipv6_only)
|
||||
"remote-dns-address":
|
||||
"https://dns.google/dns-query", // 使用 Google DoH,避免中转节点 DNS 死锁
|
||||
"remote-dns-domain-strategy": "prefer_ipv4",
|
||||
"direct-dns-address": "local", // 使用系统 DNS,确保中转服务器域名能被解析
|
||||
"direct-dns-domain-strategy": "prefer_ipv4",
|
||||
"remote-dns-address": remoteDnsAddress, // 使用 Google DoH,避免中转节点 DNS 死锁
|
||||
"remote-dns-domain-strategy": dnsDomainStrategy,
|
||||
"direct-dns-address": directDnsAddress, // 使用系统 DNS,确保中转服务器域名能被解析
|
||||
"direct-dns-domain-strategy": dnsDomainStrategy,
|
||||
"mixed-port": kr_port,
|
||||
"tproxy-port": kr_port,
|
||||
"local-dns-port": 36450,
|
||||
|
||||
Reference in New Issue
Block a user