Heyo heyo
So I’ve been working on writing a wrapper for the libssh library recently, and I think it’s ready-ish enough for others to use (if they dare ).
Source: GitHub - JuliaWeb/LibSSH.jl: A Julia wrapper for libssh.
Docs: https://juliaweb.github.io/LibSSH.jl
TL;DR: this lets you do SSH things programmatically. Here’s a peek of the API:
import LibSSH as ssh
session = ssh.Session("foo.com")
ssh.userauth_password(session, "password")
close(session)
And a bigger example here: Examples · LibSSH
Libssh (the C library) can work in both a blocking and non-blocking mode. LibSSH.jl sets everything to use the non-blocking mode by default and it’s fully compatible with Julia’s event loop, so you can safely call all of the high-level functions without needing to worry about them blocking. The low-level functions are pure wrappers to the C functions and may block or otherwise do strange things (check the excellent libssh docs before using them).
Disclaimer: the package is still young and there may be bugs and missing functionality (well ok, there’s definitely lots of missing functionality)
Having said that, the implementation of the SSH protocol itself is entirely delegated to libssh, which is a fairly trusted library, so I’m mildly confident that there’s at least no severe security issues.