XTLS / Xray-core

Xray, Penetrates Everything. Also the best v2ray-core, with XTLS support. Fully compatible configuration.
https://t.me/projectXray
Mozilla Public License 2.0
25.03k stars 3.9k forks source link

SS 2022 无法与 KCP 一起使用 #1144

Closed MuenYu closed 6 months ago

MuenYu commented 2 years ago

复现版本: xray 1.5.6-1.5.9

配置文件: 服务端

                {
                        "listen": "0.0.0.0",
                        "port": 1234,
                        "protocol": "shadowsocks",
                        "settings": {
                                "method": "2022-blake3-aes-128-gcm",
                                "password": "{{ PSK }}",
                                "network": "tcp,udp"
                        },
                        "streamSettings": {
                                "network": "kcp",
                                "kcpSettings": {
                                        "mtu": 1350,
                                        "tti": 20,
                                        "uplinkCapacity": 100,
                                        "downlinkCapacity": 100,
                                        "congestion": false,
                                        "readBufferSize": 2,
                                        "writeBufferSize": 2,
                                        "header": {
                                                "type": "{{ type }}"
                                        },
                                        "seed": "{{ seed }}"
                                }
                        }
                }

客户端

        {
            "tag": "free",
            "protocol": "shadowsocks",
            "settings": {
                "servers": [
                    {
                        "address": "{{ ip }}",
                        "port": 1234,
                        "method": "2022-blake3-aes-128-gcm",
                        "password": "{{ PSK }}",
                        "uot": true
                    }
                ]
            },
            "streamSettings": {
                "network": "kcp",
                "kcpSettings": {
                    "mtu": 1350,
                    "tti": 20,
                    "uplinkCapacity": 100,
                    "downlinkCapacity": 100,
                    "congestion": false,
                    "readBufferSize": 2,
                    "writeBufferSize": 2,
                    "header": {
                        "type": "{{ type }}"
                    },
                    "seed": "{{ seed }}"
                }
            }
        }

错误日志

app/proxyman/inbound: connection ends > shadowsocks: serve UDP from {{ client_ip }}:{{ client_port }}: decrypt packet: cipher: message authentication failed

不使用 kcp 时可以正常使用

Fangliding commented 2 years ago

@parasomn1a 上一次看到有人用KCP 还是在上次

chika0801 commented 2 years ago

虽然我没用过kcp,还是建议你用用hy 或tuic https://github.com/HyNetwork/hysteria