liudf0716 / xfrpc

The xfrpc project is a lightweight implementation of the FRP client written in C language for OpenWRT and IoT systems. It is designed to provide an efficient solution for resource-constrained devices such as OpenWRT routers and IoT devices, which often have limited ROM and RAM space.
GNU General Public License v3.0
719 stars 90 forks source link

远程连接关闭后, 本地连接还是会保持连接 #47

Open tianmax opened 1 year ago

tianmax commented 1 year ago

1.跟远程的连接关闭后,xfrpc跟本地的连接不关闭,会导致xfrpc跟本地服务的连接数不断增加 2.关闭跟frps端口的连接, 在收到FIN标记的包后, 修改标记close_stream = 1, 可以关闭链接,但是接收到的数据没能完成写入本地服务

理想状态下,应该是 1.发送完数据给frps的转发端口 2.跟frps的端口断开连接 3.xfrpc写入数据给本地服务 4.如果远程服务断开了, 则关闭跟本地服务的链接