Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

使用xray ss服务端时,将加密设置成none会导致udp转发无法开启,请解除这个限制 #1642

Closed
crmmc opened this issue Feb 10, 2023 · 5 comments

Comments

@crmmc
Copy link

crmmc commented Feb 10, 2023

xray版本:xray 1.5.5
armv7 openwrt

问题:
使用xray的ss outbound时,将加密设置成none会导致udp转发无法开启,但是设置成其他加密方式如 aes-128-gcm或者xchacha20-poly1305就可以正常启用UDP转发

理由:
在绝对可信任的内网环境时,为了降低性能羸弱的路由器的计算负担,我希望使用none加密配合SS利用xray实现服务端搭建,现在被迫使用xchacha20-poly1305搭建,在大流量高并发的条件下(大文件下载,比如挂个bt),路由器转发数据包也跟着变得吃力了。
在绝对可信的内网环境下,流量加密是不需要的。
xray拥有先进的出口数据包加FW标记的功能,而且也比v2ray的ss入口多了none和plain加密方式。希望能更加开放的让用户使用这xray特有的有点无加密,以改善用户体验。

@crmmc
Copy link
Author

crmmc commented Feb 10, 2023

出现问题的配置文件:
{
"inbounds": [
{
"port": 10888, // 服务器监听端口
"protocol": "shadowsocks",
"settings": {
"method": "none",
"password": "1",

              "network": "tcp,udp"
            }

}
],
"outbounds": [
{
"protocol": "freedom",
"streamSettings": {
"sockopt": {
"mark": 11888
}}
}
]
}

没问题的配置文件:
{
"inbounds": [
{
"port": 10888, // 服务器监听端口
"protocol": "shadowsocks",
"settings": {
"method": "xchacha20-poly1305",
"password": "1",

              "network": "tcp,udp"
            }

}
],
"outbounds": [
{
"protocol": "freedom",
"streamSettings": {
"sockopt": {
"mark": 11888
}}
}
]
}

@King-Of-Knights
Copy link

数据安全的情况下,用socks5代理就可以达到一样的效果

@crmmc
Copy link
Author

crmmc commented Feb 16, 2023

数据安全的情况下,用socks5代理就可以达到一样的效果

你好。
我的考量主要是这样的,因为socks5协议的udp转发过程可以说多了一个数据包握手,而ss的udp相比来说第一包就含有数据,资源会更节省一点。而SS也是已经写好在xray里的,这也能算是个功能bug吧,想提个pr让开发者顺便修复了
最后,感谢所有开发者。这不是催修复,只是提个pr报告bug,修不修复是您的自由。我仍然感激这个项目所有开发者的的无私奉献。

@yuhan6665
Copy link
Member

待修复 #2310 再测试

@Fangliding
Copy link
Member

经过测试已可以正常转发UDP

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants