Class SshLocalSocketForwarder
- Namespace
- SshSharp
- Assembly
- SshSharp.dll
A local forwarding that listens on a Unix socket (ssh -L /local/socket:host:port or ssh -L /local/socket:/remote/socket),
started by ForwardLocalUnixSocketAsync(string, string, int, CancellationToken) or its overload: connections to
the socket LocalSocketPath are relayed through the server to RemoteHost:RemotePort, or to
the Unix socket RemoteSocketPath on the server. The socket file is owner-only. Dispose it to stop listening, close the
forwarded connections and remove the socket file.
public sealed class SshLocalSocketForwarder : IAsyncDisposable
- Inheritance
-
SshLocalSocketForwarder
- Implements
- Inherited Members
Properties
- ActiveConnections
How many forwarded connections are open now.
- LocalSocketPath
The Unix socket being listened on, which this forwarder created.
- RemoteHost
Where the server connects each forwarded connection to; null when it connects to RemoteSocketPath.
- RemotePort
The port on RemoteHost; 0 when the server connects to RemoteSocketPath.
- RemoteSocketPath
The Unix socket on the server each forwarded connection goes to; null when it goes to RemoteHost.
Methods
- DisposeAsync()
Stops listening, closes every forwarded connection, and removes the socket file.