Recently I needed to do some server manipulation over the SSH-2 protocol from a Java client program. There are quite a few choices of SSH libraries for Javaout there. Usually I prefer BSD license whenever possible, so I thought I’ll give Ganymed SSH-2 for Javaa try. It turned out to be pretty simple to use. Here’s a short example of how to connect to the server using the private key and execute some command.