github.com/inazumav/sing-box@v0.0.0-20230926072359-ab51429a14f1/docs/examples/shadowsocks.md (about) 1 # Shadowsocks 2 3 !!! warning "" 4 5 For censorship bypass usage in China, we recommend using UDP over TCP and disabling UDP on the server. 6 7 ## Single User 8 9 #### Server 10 11 ```json 12 { 13 "inbounds": [ 14 { 15 "type": "shadowsocks", 16 "listen": "::", 17 "listen_port": 8080, 18 "network": "tcp", 19 "method": "2022-blake3-aes-128-gcm", 20 "password": "8JCsPssfgS8tiRwiMlhARg==" 21 } 22 ] 23 } 24 ``` 25 26 #### Client 27 28 ```json 29 { 30 "inbounds": [ 31 { 32 "type": "mixed", 33 "listen": "::", 34 "listen_port": 2080 35 } 36 ], 37 "outbounds": [ 38 { 39 "type": "shadowsocks", 40 "server": "127.0.0.1", 41 "server_port": 8080, 42 "method": "2022-blake3-aes-128-gcm", 43 "password": "8JCsPssfgS8tiRwiMlhARg==", 44 "udp_over_tcp": true 45 } 46 ] 47 } 48 49 ``` 50 51 ## Multiple Users 52 53 #### Server 54 55 ```json 56 { 57 "inbounds": [ 58 { 59 "type": "shadowsocks", 60 "listen": "::", 61 "listen_port": 8080, 62 "method": "2022-blake3-aes-128-gcm", 63 "password": "8JCsPssfgS8tiRwiMlhARg==", 64 "users": [ 65 { 66 "name": "sekai", 67 "password": "BXYxVUXJ9NgF7c7KPLQjkg==" 68 } 69 ] 70 } 71 ] 72 } 73 ``` 74 75 #### Client 76 77 ```json 78 { 79 "inbounds": [ 80 { 81 "type": "mixed", 82 "listen": "::", 83 "listen_port": 2080 84 } 85 ], 86 "outbounds": [ 87 { 88 "type": "shadowsocks", 89 "server": "127.0.0.1", 90 "server_port": 8080, 91 "method": "2022-blake3-aes-128-gcm", 92 "password": "8JCsPssfgS8tiRwiMlhARg==:BXYxVUXJ9NgF7c7KPLQjkg==" 93 } 94 ] 95 } 96 97 ``` 98 99 ## Relay 100 101 #### Server 102 103 ```json 104 { 105 "inbounds": [ 106 { 107 "type": "shadowsocks", 108 "listen": "::", 109 "listen_port": 8080, 110 "method": "2022-blake3-aes-128-gcm", 111 "password": "8JCsPssfgS8tiRwiMlhARg==" 112 } 113 ] 114 } 115 ``` 116 117 #### Relay 118 119 ```json 120 { 121 "inbounds": [ 122 { 123 "type": "shadowsocks", 124 "listen": "::", 125 "listen_port": 8081, 126 "method": "2022-blake3-aes-128-gcm", 127 "password": "BXYxVUXJ9NgF7c7KPLQjkg==", 128 "destinations": [ 129 { 130 "name": "my_server", 131 "password": "8JCsPssfgS8tiRwiMlhARg==", 132 "server": "127.0.0.1", 133 "server_port": 8080 134 } 135 ] 136 } 137 ] 138 } 139 ``` 140 141 #### Client 142 143 ```json 144 { 145 "inbounds": [ 146 { 147 "type": "mixed", 148 "listen": "::", 149 "listen_port": 2080 150 } 151 ], 152 "outbounds": [ 153 { 154 "type": "shadowsocks", 155 "server": "127.0.0.1", 156 "server_port": 8081, 157 "method": "2022-blake3-aes-128-gcm", 158 "password": "8JCsPssfgS8tiRwiMlhARg==:BXYxVUXJ9NgF7c7KPLQjkg==" 159 } 160 ] 161 } 162 163 ```