156 lines
3.1 KiB
JSON
156 lines
3.1 KiB
JSON
{
|
|
"log": {
|
|
"level": "info",
|
|
"timestamp": true
|
|
},
|
|
"dns": {
|
|
"servers": [
|
|
{
|
|
"tag": "proxyDns",
|
|
"address": "tls://8.8.8.8",
|
|
"detour": "Proxy"
|
|
},
|
|
{
|
|
"tag": "localDns",
|
|
"address": "8.8.8.8",
|
|
"detour": "direct"
|
|
}
|
|
],
|
|
"rules": [
|
|
{
|
|
"outbound": "any",
|
|
"server": "localDns"
|
|
},
|
|
{
|
|
"rule_set": "geosite-ir",
|
|
"server": "proxyDns"
|
|
},
|
|
{
|
|
"clash_mode": "direct",
|
|
"server": "localDns"
|
|
},
|
|
{
|
|
"clash_mode": "global",
|
|
"server": "proxyDns"
|
|
}
|
|
],
|
|
"final": "localDns",
|
|
"strategy": "ipv4_only"
|
|
},
|
|
"inbounds": [
|
|
{
|
|
"type": "tun",
|
|
"tag": "tun-in",
|
|
"address": "172.19.0.1/30",
|
|
"auto_route": true,
|
|
"strict_route": true
|
|
}
|
|
],
|
|
"outbounds": [
|
|
{
|
|
"tag": "Proxy",
|
|
"type": "selector",
|
|
"outbounds": [
|
|
"auto",
|
|
"direct"
|
|
]
|
|
},
|
|
{
|
|
"tag": "Global",
|
|
"type": "selector",
|
|
"outbounds": [
|
|
"direct"
|
|
]
|
|
},
|
|
{
|
|
"tag": "auto",
|
|
"type": "urltest",
|
|
"outbounds": [
|
|
"Proxy"
|
|
],
|
|
"url": "http://www.gstatic.com/generate_204",
|
|
"interval": "10m",
|
|
"tolerance": 50
|
|
},
|
|
{
|
|
"type": "direct",
|
|
"tag": "direct"
|
|
},
|
|
{
|
|
"type": "direct",
|
|
"tag": "local"
|
|
}
|
|
],
|
|
"route": {
|
|
"auto_detect_interface": true,
|
|
"final": "Proxy",
|
|
"rules": [
|
|
{
|
|
"inbound": [
|
|
"tun-in",
|
|
"mixed-in"
|
|
],
|
|
"action": "sniff"
|
|
},
|
|
{
|
|
"type": "logical",
|
|
"mode": "or",
|
|
"rules": [
|
|
{
|
|
"port": 53
|
|
},
|
|
{
|
|
"protocol": "dns"
|
|
}
|
|
],
|
|
"action": "hijack-dns"
|
|
},
|
|
{
|
|
"rule_set": "geosite-category-ads-all",
|
|
"action": "reject"
|
|
},
|
|
{
|
|
"rule_set": "geosite-category-ads-all",
|
|
"outbound": "Proxy"
|
|
},
|
|
{
|
|
"ip_is_private": true,
|
|
"outbound": "direct"
|
|
},
|
|
{
|
|
"action": "route",
|
|
"rule_set": "geosite-ir",
|
|
"outbound": "direct"
|
|
},
|
|
{
|
|
"action": "route",
|
|
"rule_set": "geoip-ir",
|
|
"outbound": "direct"
|
|
}
|
|
],
|
|
"rule_set": [
|
|
{
|
|
"tag": "geosite-category-ads-all",
|
|
"type": "remote",
|
|
"format": "binary",
|
|
"url": "https://raw.githubusercontent.com/Chocolate4U/Iran-sing-box-rules/rule-set/geosite-category-ads-all.srs",
|
|
"download_detour": "direct"
|
|
},
|
|
{
|
|
"type": "remote",
|
|
"tag": "geoip-ir",
|
|
"format": "binary",
|
|
"url": "https://raw.githubusercontent.com/Chocolate4U/Iran-sing-box-rules/rule-set/geoip-ir.srs",
|
|
"update_interval": "120h0m0s"
|
|
},
|
|
{
|
|
"type": "remote",
|
|
"tag": "geosite-ir",
|
|
"format": "binary",
|
|
"url": "https://raw.githubusercontent.com/Chocolate4U/Iran-sing-box-rules/rule-set/geosite-ir.srs",
|
|
"update_interval": "120h0m0s"
|
|
}
|
|
]
|
|
}
|
|
}
|