Automating SSH commands in Java