Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import ssh
- hostname = "133.242.150.240"
- username = "ims"
- password = "naka336"
- port = 10022
- client = ssh.SSHClient()
- client.load_system_host_keys()
- client.connect(hostname, username=username, password=password, port=port)
- stdin, stdout, stderr = client.exec_command("ls -la")
- for l in stdout.read().split("\n"):
- print l
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement