github.com/sagernet/sing-box@v1.9.0-rc.20/docs/configuration/inbound/shadowsocks.zh.md (about) 1 ### 结构 2 3 ```json 4 { 5 "type": "shadowsocks", 6 "tag": "ss-in", 7 8 ... // 监听字段 9 10 "method": "2022-blake3-aes-128-gcm", 11 "password": "8JCsPssfgS8tiRwiMlhARg==", 12 "multiplex": {} 13 } 14 ``` 15 16 ### 多用户结构 17 18 ```json 19 { 20 "method": "2022-blake3-aes-128-gcm", 21 "password": "8JCsPssfgS8tiRwiMlhARg==", 22 "users": [ 23 { 24 "name": "sekai", 25 "password": "PCD2Z4o12bKUoFa3cC97Hw==" 26 } 27 ], 28 "multiplex": {} 29 } 30 ``` 31 32 ### 中转结构 33 34 ```json 35 { 36 "type": "shadowsocks", 37 "method": "2022-blake3-aes-128-gcm", 38 "password": "8JCsPssfgS8tiRwiMlhARg==", 39 "destinations": [ 40 { 41 "name": "test", 42 "server": "example.com", 43 "server_port": 8080, 44 "password": "PCD2Z4o12bKUoFa3cC97Hw==" 45 } 46 ], 47 "multiplex": {} 48 } 49 ``` 50 51 ### Listen Fields 52 53 See [Listen Fields](/configuration/shared/listen/) for details. 54 55 ### 字段 56 57 #### network 58 59 监听的网络协议,`tcp` `udp` 之一。 60 61 默认所有。 62 63 #### method 64 65 ==必填== 66 67 | 方法 | 密钥长度 | 68 |-------------------------------|------| 69 | 2022-blake3-aes-128-gcm | 16 | 70 | 2022-blake3-aes-256-gcm | 32 | 71 | 2022-blake3-chacha20-poly1305 | 32 | 72 | none | / | 73 | aes-128-gcm | / | 74 | aes-192-gcm | / | 75 | aes-256-gcm | / | 76 | chacha20-ietf-poly1305 | / | 77 | xchacha20-ietf-poly1305 | / | 78 79 #### password 80 81 ==必填== 82 83 | 方法 | 密码格式 | 84 |---------------|------------------------------------------| 85 | none | / | 86 | 2022 methods | `sing-box generate rand --base64 <密钥长度>` | 87 | other methods | 任意字符串 | 88 89 #### multiplex 90 91 参阅 [多路复用](/zh/configuration/shared/multiplex#inbound)。