wez / wezterm

A GPU-accelerated cross-platform terminal emulator and multiplexer written by @wez and implemented in Rust
https://wezfurlong.org/wezterm/
Other
14.94k stars 677 forks source link

Support ProxyCommand for SSH connections #233

Closed vseguip closed 3 years ago

vseguip commented 4 years ago

Wezterm supports SSH connections via libssh2 which means it does not support ProxyCommand in ssh_config. This makes connections from outside the internal network at work fail since they need to go through a proxy. It would be nice if wezterm supported ProxyCommand either by using the ssh crate (libssh supports ssh_config out of the box) or by implementing the same mechanism with libssh2.

wez commented 3 years ago

The current state of the main branch has improved ssh support; we still use libssh2 under the covers, but now parse and understand a number of options from ssh_config, as well as allow specifying them from the command line:

wezterm ssh "-oProxyCommand=nc localhost 22" localhost
SuperSandro2000 commented 3 years ago

Does it use libssh2 to also parse the ssh_config file?

wez commented 3 years ago

libssh2 doesn't parse ssh_config files. wezterm has its own code to parse those files here: https://github.com/wez/wezterm/blob/main/wezterm-ssh/src/config.rs

github-actions[bot] commented 1 year ago

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.