mirror of
https://github.com/MatsuriDayo/nekoray.git
synced 2025-12-18 22:20:09 +08:00
152 lines
3.7 KiB
JSON
152 lines
3.7 KiB
JSON
{
|
|
"log": {
|
|
"level": "info"
|
|
},
|
|
"dns": {
|
|
"fakeip": {
|
|
"enabled": true,
|
|
"inet4_range": "198.18.0.0/15",
|
|
"inet6_range": "fc00::/18"
|
|
},
|
|
"servers": [
|
|
{
|
|
"tag": "dns-remote",
|
|
"address": "8.8.8.8",
|
|
"detour": "neko-socks"
|
|
},
|
|
{
|
|
"tag": "dns-direct",
|
|
"address": "%DNS_ADDRESS%",
|
|
"detour": "direct"
|
|
},
|
|
{
|
|
"address": "fakeip",
|
|
"tag": "dns-fake"
|
|
},
|
|
{
|
|
"address": "rcode://success",
|
|
"tag": "dns-block"
|
|
}
|
|
],
|
|
"rules": [
|
|
{
|
|
"query_type": [
|
|
32,
|
|
33
|
|
],
|
|
"server": "dns-block"
|
|
},
|
|
{
|
|
"domain_suffix": [
|
|
".lan"
|
|
],
|
|
"server": "dns-block"
|
|
},
|
|
{
|
|
"process_name": [
|
|
"nekoray_core",
|
|
"nekoray_core.exe",
|
|
"nekobox_core",
|
|
"nekobox_core.exe"
|
|
],
|
|
"server": "dns-direct"
|
|
},
|
|
{
|
|
"inbound": "%FAKE_DNS_INBOUND%",
|
|
"server": "dns-fake"
|
|
}
|
|
]
|
|
},
|
|
"inbounds": [
|
|
{
|
|
"type": "tun",
|
|
"tag": "tun-in",
|
|
"interface_name": "%TUN_NAME%",
|
|
"inet4_address": "172.19.0.1/28",
|
|
//%IPV6_ADDRESS%
|
|
"mtu": %MTU%,
|
|
"auto_route": true,
|
|
"strict_route": %STRICT_ROUTE%,
|
|
"stack": "%STACK%",
|
|
"endpoint_independent_nat": true,
|
|
"sniff": false
|
|
}
|
|
],
|
|
"outbounds": [
|
|
{
|
|
"type": "socks",
|
|
"tag": "neko-socks",
|
|
"udp_fragment": true,
|
|
//%SOCKS_USER_PASS%
|
|
"server": "127.0.0.1",
|
|
"server_port": %PORT%
|
|
},
|
|
{
|
|
"type": "block",
|
|
"tag": "block"
|
|
},
|
|
{
|
|
"type": "direct",
|
|
"tag": "direct"
|
|
},
|
|
{
|
|
"type": "dns",
|
|
"tag": "dns-out"
|
|
}
|
|
],
|
|
"route": {
|
|
"final": "%FINAL_OUT%",
|
|
"auto_detect_interface": true,
|
|
"rules": [
|
|
{
|
|
"network": "udp",
|
|
"port": [
|
|
135,
|
|
137,
|
|
138,
|
|
139,
|
|
5353
|
|
],
|
|
"outbound": "block"
|
|
},
|
|
{
|
|
"ip_cidr": [
|
|
"224.0.0.0/3",
|
|
"ff00::/8"
|
|
],
|
|
"outbound": "block"
|
|
},
|
|
{
|
|
"source_ip_cidr": [
|
|
"224.0.0.0/3",
|
|
"ff00::/8"
|
|
],
|
|
"outbound": "block"
|
|
},
|
|
{
|
|
"port": 53,
|
|
"process_name": [
|
|
"nekoray_core",
|
|
"nekoray_core.exe"
|
|
],
|
|
"outbound": "dns-out"
|
|
},
|
|
{
|
|
"process_name": [
|
|
"nekoray_core",
|
|
"nekoray_core.exe",
|
|
"nekobox_core",
|
|
"nekobox_core.exe"
|
|
],
|
|
"outbound": "direct"
|
|
}
|
|
//%PROCESS_NAME_RULE%
|
|
//%CIDR_RULE%
|
|
,
|
|
{
|
|
"port": 53,
|
|
"outbound": "dns-out"
|
|
}
|
|
]
|
|
}
|
|
} |