• Stars
    star
    256
  • Rank 153,718 (Top 4 %)
  • Language
    Java
  • License
    Other
  • Created over 9 years ago
  • Updated 8 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Java SSH client (an object-oriented wrapper around JSch)

logo

EO principles respected here DevOps By Rultor.com

mvn PDD status Maven Central Javadoc codecov Hits-of-Code jpeek report License Codacy Badge

More details are here: ssh.jcabi.com.

Also, read this blog post: Simple Java SSH Client.

It is a convenient SSH client for Java:

import com.jcabi.ssh.Shell;
import com.jcabi.ssh.Ssh;
Shell shell = new Ssh("example.com", 22, "username", "key...");
String stdout = new Shell.Plain(shell).exec("echo 'Hello, world!'");

The key here is your private SSH key, usually the one you have in ~/.ssh/id_rsa.

There is also a convenient SSHD class, a runner of ssh daemon, for unit testing:

try (Sshd sshd = new Sshd()) {
  String uptime = new Shell.Plain(
    Ssh(sshd.host(), sshd.login(), sshd.port(), sshd.key())
  ).exec("uptime");
}

Version 1.6 works under Java 1.8+. If your Java version is ealier, use version 1.5.2.

How to contribute?

Fork the repository, make changes, submit a pull request. We promise to review your changes same day and apply to the master branch, if they look correct.

Please run Maven (3.2+) build before submitting a pull request:

$ mvn clean install -Pqulice

Make sure you have Maven 3.3+ and Java 8+.

More Repositories

1

jcabi-aspects

Collection of AspectJ Java Aspects to facilitate aspect-oriented programming patterns: logging, caching, validating, etc.
Java
506
star
2

jcabi-github

Java Object-Oriented Wrapper of GitHub API, with a fake implementation of the entire GitHub API (for your tests)
Java
291
star
3

jcabi-http

Fluent Java HTTP client
Java
148
star
4

jcabi-jdbc

Fluent Object-Oriented Wrapper of JDBC
Java
101
star
5

jcabi-xml

Java XML Parsing, Transforming, Printing, and Validating
Java
95
star
6

jcabi

Elementary Java components, each in its own repository and its own Maven artifact
89
star
7

jcabi-aether

Wrapper of Sonatype Aether
Java
61
star
8

jcabi-manifests

Java library for convenient reading of MANIFEST.MF files available in classpath
Java
57
star
9

jcabi-log

Static Wrapper of SLF4J easing you from the necessity to create static LOGGER instances in each Java class
Java
55
star
10

jcabi-email

Object-Oriented Email Sending Java SDK
Java
52
star
11

jcabi-dynamo

Object Oriented Wrapper of AWS DynamoDB SDK
Java
47
star
12

jcabi-parent

A convenient parent Maven POM artifact, which we recommend using in all Maven projects
Java
42
star
13

jcabi-mysql-maven-plugin

MySQL Maven Plugin: starts MySQL server on pre-integration phase and shuts it down on post-integration phase
Java
34
star
14

jcabi-immutable

Immutable Collections
Java
30
star
15

jcabi-dynamodb-maven-plugin

DynamoDB Local Maven Plugin: starts and stops a local test server
Java
30
star
16

jcabi-maven-plugin

Supplementary maven plugin for AspectJ weaving and versioning of artifacts
Java
28
star
17

jcabi-s3

Object-Oriented Layer on Top of Amazon S3 SDK
Java
27
star
18

jcabi-w3c

W3C Validators in Java
Java
18
star
19

jcabi-urn

Java URN as in RFC 2141
Java
16
star
20

jcabi-maven-slf4j

SLF4J Binding for Apache Maven
Java
14
star
21

jcabi-simpledb

Object-Oriented Java SDK for Amazon SimpleDB
Java
13
star
22

jcabi-matchers

A few convenient Hamcrest matchers, mostly for XPath vs XHTML and fields in JAXB
Java
13
star
23

jcabi-beanstalk-maven-plugin

Maven Plugin for AWS Elastic Beanstalk
Java
11
star
24

jcabi-velocity

Wrapper of Apache Velocity
Java
11
star
25

jcabi-odesk

Object-Oriented oDesk Java SDK
Java
10
star
26

jcabi-ssl-maven-plugin

SSL Plugin for Apache Maven: it generates fake SSL certificates for the testing purposes of your Java web app
Java
10
star
27

jcabi-heroku-maven-plugin

Maven Plugin for Deploying to Heroku
Java
8
star
28

jcabi-maven-skin

Skin for Apache Maven
SCSS
8
star
29

jcabi-latex-maven-plugin

LaTeX Maven Plugin
Java
7
star
30

.github

Front page
2
star