{ "log": { "level": "warn", "output": "box.log", "timestamp": true }, "dns": { "servers": [ { "tag": "dns-remote", "address": "udp://1.1.1.1", "address_resolver": "dns-direct", "detour": "select" }, { "tag": "dns-direct", "address": "1.1.1.1", "address_resolver": "dns-local", "detour": "direct" }, { "tag": "dns-local", "address": "local", "detour": "direct" }, { "tag": "dns-block", "address": "rcode://success" } ], "rules": [ { "domain": "engage.cloudflareclient.com", "server": "dns-direct" }, { "domain_suffix": ".ir", "geosite": "ir", "server": "dns-direct" }, { "domain": "cp.cloudflare.com", "server": "dns-remote", "rewrite_ttl": 3000 } ], "final": "dns-remote", "independent_cache": true }, "inbounds": [ { "type": "tun", "tag": "tun-in", "mtu": 9000, "inet4_address": "172.19.0.1/28", "auto_route": true, "strict_route": true, "endpoint_independent_nat": true, "sniff": true, "sniff_override_destination": true }, { "type": "mixed", "tag": "mixed-in", "listen": "0.0.0.0", "listen_port": 2334, "sniff": true, "sniff_override_destination": true }, { "type": "direct", "tag": "dns-in", "listen": "0.0.0.0", "listen_port": 6440, "override_address": "1.1.1.1", "override_port": 53 } ], "outbounds": [ { "type": "selector", "tag": "select", "outbounds": [ "auto", "u0", "u1" ], "default": "auto" }, { "type": "urltest", "tag": "auto", "outbounds": [ "u0", "u1" ], "url": "http://cp.cloudflare.com/", "interval": "10m0s" }, { "type": "wireguard", "tag": "u0", "local_address": [ "172.16.0.2/32","2606:4700:110:86ed:83e4:4cb1:c7f8:2aef/128" ], "private_key": "YLLznV1dk/DMeSkrhXmvN+bdh/XXr1UZMp5iPXLgGUg=", "server": "188.114.96.185", "server_port": 939, "peer_public_key": "bmXOC+F1FxEMF9dyiK2H5/1SUtzH0JuVo51h2wPfgyo=", "reserved": [ 127,90,114 ], "mtu": 1280, "fake_packets": "20-35", "fake_packets_size": "5-35", "fake_packets_delay": "5-35", "fake_packets_mode": "m4" }, { "type": "wireguard", "tag": "u1", "detour": "u0", "local_address": [ "172.16.0.2/32","2606:4700:110:8c41:7cbc:b82d:1acd:4fd/128" ], "private_key": "OC8byGVfFaoLeBmYy0GSmbeeT9oQdo/PvJyw69CufWU=", "server": "188.114.96.200", "server_port": 1701, "peer_public_key": "bmXOC+F1FxEMF9dyiK2H5/1SUtzH0JuVo51h2wPfgyo=", "reserved": [ 133,87,18 ], "mtu": 1280, "fake_packets": "20-35", "fake_packets_size": "5-35", "fake_packets_delay": "5-35", "fake_packets_mode": "m4" }, { "type": "dns", "tag": "dns-out" }, { "type": "direct", "tag": "direct" }, { "type": "direct", "tag": "bypass" }, { "type": "block", "tag": "block" } ], "route": { "geoip": { "path": "geo-assets/sagernet-sing-geoip-geoip.db" }, "geosite": { "path": "geo-assets/sagernet-sing-geosite-geosite.db" }, "rules": [ { "inbound": "dns-in", "outbound": "dns-out" }, { "port": 53, "outbound": "dns-out" }, { "clash_mode": "Direct", "outbound": "direct" }, { "clash_mode": "Global", "outbound": "select" }, { "geoip": "private", "outbound": "bypass" }, { "domain_suffix": ".ir", "geosite": "ir", "geoip": "ir", "outbound": "bypass" } ], "auto_detect_interface": true, "override_android_vpn": true }, "experimental": { "cache_file": { "enabled": true, "path": "clash.db" }, "clash_api": { "external_controller": "127.0.0.1:6756" } } }