feat(client): implement port forwarding — local (-L) and remote (-R) forwards
- PortForwardSpec parses -L/-R spec strings: bind_addr:bind_port:target_host:target_port - LocalForwarder binds TcpListener, accepts connections, opens SSH direct-tcpip channel, proxies bidirectionally - RemoteForwarder sends tcpip_forward request, handles forwarded-tcpip channel opens, connects local target, proxies bidirectionally - Both forwarders run concurrently with SOCKS5 server via Arc<Mutex<Handle>> - Connection errors close individual channels without affecting other forwards or SSH session - ForwardError type added with display and source chaining tests - Unit tests: spec parsing, local forward bind/accept, remote forward proxy bidirectional
This commit is contained in:
@@ -8,5 +8,5 @@ pub mod error;
|
||||
#[cfg(feature = "testutil")]
|
||||
pub mod testutil;
|
||||
|
||||
pub use error::{AuthError, ChannelError, ConfigError, TransportError};
|
||||
pub use error::{AuthError, ChannelError, ConfigError, ForwardError, TransportError};
|
||||
pub use transport::{Transport, TransportAcceptor, TransportInfo, TransportKind};
|
||||
Reference in New Issue
Block a user