Skip to content
This repository has been archived by the owner on Jan 4, 2024. It is now read-only.

ssh代理存在连接泄露问题 #458

Closed
xxxsen opened this issue May 8, 2022 · 7 comments
Closed

ssh代理存在连接泄露问题 #458

xxxsen opened this issue May 8, 2022 · 7 comments
Labels
help wanted Extra attention is needed not following template

Comments

@xxxsen
Copy link

xxxsen commented May 8, 2022

Before submitting an issue, please make sure you are using the latest version of SagerNet.

Describe the bug

2个问题。

  • 在app界面内关闭ssh代理(ui右下角的按钮), 服务端无法正常回收连接(需要整个app关闭后才能正常关闭)。
  • 通过ssh代理的连接, 在对端关闭后, 服务端无法回收连接, 会一直处于close_wait状态。

To Reproduce

Steps to reproduce the behavior:

对于问题1:

  1. 部署ssh代理服务器
  2. 初始化安装sagernet, 配置ssh代理
  3. 创建vpn连接后在应用内进行关闭
  4. 反复重试步骤3, 每重复一次, 必定导致一个链接泄露

对于问题2:

进行ssh代理后, 随便访问一些网站, 之后在服务端执行netstat -plan |grep CLOSE_WAIT, 会发现存在很多处于CLOSE WAIT状态的连接无法正常关闭。

Debug Information

About -> Export Debug Information

# 没有日志, 按上面步骤即可复现。

Expected behavior

ssh代理能正常回收关闭的链接。

Screenshots

反复开关vpn后创建出来的链接:
image

app关闭后链接被释放
image

问题2的复现截图。
image

Smartphone (please complete the following information)

  • Kernel version: -
  • Device: One plus 7p
  • OS: Android 12

Additional context

app版本

Version: 0.8-beta02
Version(Sagernet/v2ray-core): v5.0.9

@xxxsen
Copy link
Author

xxxsen commented May 8, 2022

关联下。。
https://github.com/MatsuriDayo/Matsuri/issues/30

@nekohasekai
Copy link
Member

nekohasekai commented May 8, 2022

SagerNet/v2ray-core@4ca3922 重试,如仍有问题,提交日志。

@nekohasekai nekohasekai added help wanted Extra attention is needed not following template labels May 8, 2022
@xxxsen
Copy link
Author

xxxsen commented May 8, 2022

@nekohasekai 从哪里下载构建产物呢,没编译过安卓程序。。

@nekohasekai
Copy link
Member

直接运行 core。

@xxxsen
Copy link
Author

xxxsen commented May 8, 2022

第二个问题验证ok,但是第一个问题,没有apk,我这边也没法验证。。

@xxxsen
Copy link
Author

xxxsen commented May 8, 2022

第二个问题验证ok,但是第一个问题,没有apk,我这边也没法验证。。

@nekohasekai 你的应用应该是之前core更新了, 但是sagernet没有更新, v2ray-core@v5.0.9的这个tag, 是已经修复了的, 刚刚测试了下v5.0.8的有问题, v5.0.9是正常的, 但是sagernet@0.8-beta02 这个tag里面显示的v2ray-core的版本是v5.0.9, 实际上却还是有问题。

Screenshot_20220508-214643_SagerNet

@arm64v8a
Copy link
Contributor

SagerNet/v2ray-core@4ca3922

我用 core 测试,转发的连接关闭后,服务器侧正常进入 TIME_WAIT,应该是修复了。

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
help wanted Extra attention is needed not following template
Projects
None yet
Development

No branches or pull requests

3 participants