Package com.jcabi.ssh
SSH client.
Usage scenario is very simple:
String hello = new Shell.Plain( new SSH( "ssh.example.com", 22, "yegor", "-----BEGIN RSA PRIVATE KEY-----..." ) ).exec("echo 'Hello, world!'");
The only dependency you need is (check our latest version available at ssh.jcabi.com):
<depedency> <groupId>com.jcabi</groupId> <artifactId>jcabi-ssh</artifactId> </dependency>
- Since:
- 1.0
- See Also:
- project website, article by Yegor Bugayenko
-
Interface Summary Interface Description Shell Shell. -
Class Summary Class Description Shell.Empty Without input and output.Shell.Fake Fake shell for unit testing.Shell.Plain With output only.Shell.Safe Safe run (throws if exit code is not zero).Shell.Verbose Verbose run.Ssh Single SSH Channel.SshByPassword SSH channel with authentication by password.Sshd Test SSHD daemon (only for Linux).