{ "inbounds": [ { "tag": "transparent", "port": 12345, "listen": "0.0.0.0", "protocol": "dokodemo-door", "settings": { "network": "tcp,udp", "followRedirect": true }, "sniffing": { "enabled": true, "destOverride": [ "http", "tls" ] }, "streamSettings": { "sockopt": { "tproxy": "tproxy" } } }, { "port": 1080, "listen": "127.0.0.1", "protocol": "socks", "sniffing": { "enabled": true, "destOverride": [ "http", "tls" ] }, "settings": { "auth": "noauth" } }, { "port": 8118, "listen": "127.0.0.1", "protocol": "http", "settings": { "timeout": 0, "userLevel": 0 } } ], "outbounds": [ { "tag": "proxy", "protocol": "vmess", "mux": { "enabled": true }, "settings": { "vnext": [ { "address": "serveraddr.com", "port": 443, "users": [ { "id": "UUID-UUID-UUID-UUID" } ] } ] }, "streamSettings": { "network": "ws", "security": "tls", "wsSettings": { "path": "/ray" }, "sockopt": { "mark": 255 } } }, { "tag": "direct", "protocol": "freedom", "settings": { "domainStrategy": "UseIP" }, "streamSettings": { "sockopt": { "mark": 255 } } }, { "tag": "block", "protocol": "blackhole", "settings": { "response": { "type": "http" } } }, { "tag": "dns-out", "protocol": "dns", "streamSettings": { "sockopt": { "mark": 255 } } } ], "dns": { "servers": [ { "address": "223.5.5.5", "port": 53, "domains": [ "ntp.org", "serveraddr.com" ] }, { "address": "223.5.5.5", "port": 53, "domains": [ "geosite:cn" ], "expectIPs": [ "geoip:cn" ] }, { "address": "8.8.8.8", "port": 53, "domains": [ "geosite:geolocation-!cn", "geosite:speedtest" ] }, "223.5.5.5" ] }, "routing": { "domainStrategy": "IPOnDemand", "rules": [ { "type": "field", "inboundTag": [ "transparent" ], "port": 53, "network": "udp", "outboundTag": "dns-out" }, { "type": "field", "inboundTag": [ "transparent" ], "port": 123, "network": "udp", "outboundTag": "direct" }, { "type": "field", "ip": [ "223.5.5.5", "114.114.114.114" ], "outboundTag": "direct" }, { "type": "field", "ip": [ "8.8.8.8", "1.1.1.1" ], "outboundTag": "proxy" }, { "type": "field", "domain": [ "geosite:category-ads-all" ], "outboundTag": "block" }, { "type": "field", "protocol": [ "bittorrent" ], "outboundTag": "direct" }, { "type": "field", "ip": [ "geoip:private", "geoip:cn" ], "outboundTag": "direct" }, { "type": "field", "domain": [ "geosite:cn" ], "outboundTag": "direct" } ] } }