snail007/goproxy

我在使用贵项目做socket5代理支撑FTP传输时发现,底层用TCP协议可以通,但是KCP协议WARN handshake fail, ERR: new methods request fail,ERR: timeout,希望解决这个问题

jzbg opened this issue · 0 comments

jzbg commented

我在使用贵项目做socket5代理支撑FTP传输时发现,底层用TCP协议可以通,但是KCP协议不通,希望解决这个问题

Expected Behavior

我在使用贵项目做socket5代理支撑FTP传输时发现,底层用TCP协议可以通,但是KCP协议不通,希望解决这个问题

Current Behavior

这是我的一级代理日志,kcp用38080端口,ftp客户端在握手时,代理日志出现WARN handshake fail, ERR: new methods request fail,ERR: timeout
C:\Users\Administrator\Desktop\proxy124>proxy socks -t kcp -p ":38080" --kcp-key
mypassword
2023/01/10 17:20:36.450980 INFO kcp socks proxy on 0.0.0.0:38080
2023/01/10 17:20:41.491480 INFO use parent false : 192.168.1.112:21
2023/01/10 17:20:41.492480 INFO conn 192.168.1.31:60263 - 0.0.0.0:38080 <-> 192.
168.1.32:55278 - 192.168.1.32:55278 connected [192.168.1.112:21]
2023/01/10 17:20:42.411480 INFO use parent false : 192.168.1.112:62186
2023/01/10 17:20:42.411480 INFO conn 192.168.1.31:60264 - 0.0.0.0:38080 <-> 192.
168.1.32:55279 - 192.168.1.32:55279 connected [192.168.1.112:62186]
2023/01/10 17:20:42.412480 INFO conn 192.168.1.31:60264 - 0.0.0.0:38080 <-> 192.
168.1.32:55279 - 192.168.1.32:55279 released [192.168.1.112:62186]
2023/01/10 17:20:47.451480 WARN handshake fail, ERR: new methods request fail,ER
R: timeout
2023/01/10 17:20:52.531480 WARN handshake fail, ERR: new methods request fail,ER
R: timeout
2023/01/10 17:20:57.611480 WARN handshake fail, ERR: new methods request fail,ER
R: timeout
2023/01/10 17:21:02.571480 INFO use parent false : 192.168.1.112:21
2023/01/10 17:21:02.572480 INFO conn 192.168.1.31:60271 - 0.0.0.0:38080 <-> 192.
168.1.32:55282 - 192.168.1.32:55282 connected [192.168.1.112:21]
2023/01/10 17:21:02.691480 WARN handshake fail, ERR: new methods request fail,ER
R: timeout
2023/01/10 17:21:03.412480 INFO use parent false : 192.168.1.112:62187
2023/01/10 17:21:03.412480 INFO conn 192.168.1.31:60272 - 0.0.0.0:38080 <-> 192.
168.1.32:55283 - 192.168.1.32:55283 connected [192.168.1.112:62187]
2023/01/10 17:21:03.413480 INFO conn 192.168.1.31:60272 - 0.0.0.0:38080 <-> 192.
168.1.32:55283 - 192.168.1.32:55283 released [192.168.1.112:62187]

2023/01/10 17:21:03.412480 INFO use parent false : 192.168.1.112:62187
2023/01/10 17:21:03.412480 INFO conn 192.168.1.31:60272 - 0.0.0.0:38080 <-> 192.
168.1.32:55283 - 192.168.1.32:55283 connected [192.168.1.112:62187]
2023/01/10 17:21:03.413480 INFO conn 192.168.1.31:60272 - 0.0.0.0:38080 <-> 192.
168.1.32:55283 - 192.168.1.32:55283 released [192.168.1.112:62187]
一下是ftp客户端日志
状态: 连接到 192.168.1.112,通过代理 SOCKS5
状态: 正在连接 192.168.1.31:8083...
状态: 与代理连接建立,进行握手...
状态: 连接建立,等待欢迎消息...
状态: 不安全的服务器,不支持 FTP over TLS。
状态: 已连接
状态: 读取“/”的目录列表...
状态: 正在连接 192.168.1.31:8083...
状态: 与代理连接建立,进行握手...
响应: 150 Connection accepted
响应: 226 Transfer OK
错误: 20 秒后无活动,连接超时
错误: 读取目录列表失败

Possible Solution

Steps to Reproduce

1.在112启动ftp服务端
1.在32启动一级代理
1.在31启动二级代理
1.在111启动ftp客户端
客户端 连接超时

Context (Environment)

  1. proxy version is : v12.4
  2. full command is :proxy socks -t kcp -p ":38080" --kcp-key mypassword
  3. proxy socks -t tcp -p ":8083" -T kcp -P "x.x.x.x:38080" --kcp-key mypasswor
  4. system is :win7
  5. full log is: 上边已提交
  6. ftp服务端使用FileZilla0.9.41
  7. ftp客户端使用FileZilla3.14

Detailed Description

用kcp支撑socket5代理,连接ftp时,出现连接超时

Possible Implementation