From 3b1aa9d2793f5a780d6c5daa2dea26131bc8d1bb Mon Sep 17 00:00:00 2001 From: kslr Date: Sun, 22 Nov 2020 05:45:10 +0800 Subject: [PATCH] add shadowsocks --- Shadowsocks/client.json | 57 +++++++++++++++++++++++++++++++++++++++++ Shadowsocks/server.json | 41 +++++++++++++++++++++++++++++ 2 files changed, 98 insertions(+) create mode 100644 Shadowsocks/client.json create mode 100644 Shadowsocks/server.json diff --git a/Shadowsocks/client.json b/Shadowsocks/client.json new file mode 100644 index 0000000..4e2f13e --- /dev/null +++ b/Shadowsocks/client.json @@ -0,0 +1,57 @@ +{ + "log": { + "loglevel": "warning" + }, + "routing": { + "domainStrategy": "AsIs", + "rules": [ + { + "type": "field", + "ip": [ + "geoip:private" + ], + "outboundTag": "direct" + } + ] + }, + "inbounds": [ + { + "listen": "127.0.0.1", + "port": "1080", + "protocol": "socks", + "settings": { + "auth": "noauth", + "udp": true, + "ip": "127.0.0.1" + } + }, + { + "listen": "127.0.0.1", + "port": "1081", + "protocol": "http" + } + ], + "outbounds": [ + { + "protocol": "shadowsocks", + "settings": { + "servers": [ + { + "address": "{{ host }}", + "port": "{{ port }}", + "method": "chacha20-ietf-poly1305", + "password": "{{ password}}" + } + ] + }, + "streamSettings": { + "network": "tcp" + }, + "tag": "proxy" + }, + { + "protocol": "freedom", + "tag": "direct" + } + ] +} \ No newline at end of file diff --git a/Shadowsocks/server.json b/Shadowsocks/server.json new file mode 100644 index 0000000..003d3e9 --- /dev/null +++ b/Shadowsocks/server.json @@ -0,0 +1,41 @@ +{ + "log": { + "loglevel": "warning" + }, + "routing": { + "domainStrategy": "AsIs", + "rules": [ + { + "type": "field", + "ip": [ + "geoip:private" + ], + "outboundTag": "block" + } + ] + }, + "inbounds": [ + { + "listen": "0.0.0.0", + "port": 1234, + "protocol": "shadowsocks", + "settings": { + "method": "chacha20-ietf-poly1305", + "password": "{{ password }}" + }, + "streamSettings": { + "network": "tcp" + } + } + ], + "outbounds": [ + { + "protocol": "freedom", + "tag": "direct" + }, + { + "protocol": "blackhole", + "tag": "block" + } + ] +}