<PackageReference Include="SSH.NET" Version="2024.2.0" />

ChannelSession

Implements Session SSH channel.
public ChannelSession(ISession session, uint localChannelNumber, uint localWindowSize, uint localPacketSize)

Initializes a new instance of the ChannelSession class.

public void Open()

Opens the channel.

public bool SendBreakRequest(uint breakLength)

Sends the exec request.

public bool SendEndOfWriteRequest()

Sends eow@openssh.com request.

public bool SendEnvironmentVariableRequest(string variableName, string variableValue)

Sends the environment variable request.

public bool SendExecRequest(string command)

Sends the exec request.

public bool SendKeepAliveRequest()

Sends keepalive@openssh.com request.

public bool SendLocalFlowRequest(bool clientCanDo)

Sends the local flow request.

public bool SendPseudoTerminalRequest(string environmentVariable, uint columns, uint rows, uint width, uint height, IDictionary<TerminalModes, uint> terminalModeValues)

Sends the pseudo terminal request.

public bool SendShellRequest()

Sends the shell request.

public bool SendSignalRequest(string signalName)

Sends the signal request.

public bool SendSubsystemRequest(string subsystem)

Sends the subsystem request.

public bool SendWindowChangeRequest(uint columns, uint rows, uint width, uint height)

Sends the window change request.

public bool SendX11ForwardingRequest(bool isSingleConnection, string protocol, byte[] cookie, uint screenNumber)

Sends the X11 forwarding request.