Skip to content

joangq/JSSH

Repository files navigation

JSSH

A homemade wrapper to the JSch library for connecting over SSH using Java
import java.io.File;
import me.joan.jssh.Session;
import me.joan.util.PropertiesManager;
import me.joan.util.Utils;
import org.apache.logging.log4j.*;

public class Main {
    public static Logger LOGGER = LogManager.getLogger(Main.class);

    public static void main(String[] args) {
        LOGGER.info("JSSH Client starting...");
        PropertiesManager propertiesManager = new PropertiesManager(LOGGER);
        propertiesManager.load(new File("./session.properties"));

        Session JSSH = new Session(propertiesManager.getKeys(), LOGGER);
        JSSH.connect();
        JSSH.logExecuteCommand("echo Hello from the other side!");
    }
}

About

A homemade wrapper to the JSch library for connecting over SSH using Java.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages