Quantcast
Channel: sshnet Issue Tracker Rss Feed
Viewing all articles
Browse latest Browse all 1026

Created Unassigned: Sending EOF on wrong channel number. [1877]

$
0
0
In the latest version under Source Code I always gets problem with my devices that runs dropbear_0.52 after a few/seconds 10-20 seconds.

I took a look in the log on one the devices and could see that it exited because of wrong channelnumber on the EOF. Took a look in the source code and could see in the ChannelDirectTcpip.cs that it tries to send an ChannelEofMessage before calling the base.Close() of Channel.

According to the (http://www.ietf.org/rfc/rfc4254.txt , Page 8) it states that:
A party MAY send SSH_MSG_CHANNEL_CLOSE without having sent or received SSH_MSG_CHANNEL_EOF.

Made following change in the ChannelDirectTcpip class.

```
public override void Close()
{
// Close socket if still open
if (this._socket != null)
{
this._socket.Dispose();
this._socket = null;
}

// Send EOF message first when channel need to be closed
// this.SendMessage(new ChannelEofMessage(this.RemoteChannelNumber));

base.Close();
}
```
It seems to let my application to proceed with out getting disconnect by the host after a few seconds when doing requests through the localportforwarding.

Viewing all articles
Browse latest Browse all 1026

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>