1

I'd like to automate some tests performed in this way: 1)SSH Connection to a remote host usinn PuTTY 2)Telnet connection from this remote host to itself localhost 3)Command sending using telnet connection

I'd like to automate the command sequence(and logging the data) with Python. It is clear to me how to create an SSH connection with PARAMIKO but it is not clear to me how to telnet trough an SSH connection. Google-ing I think that the solution could be to create an sshtunnel but I cannot understand how to perfom the sshtunnel using Python sshtunnel class and above all how to starting telnet and sending the commands.

Vigmarco
  • 11
  • 1
  • Can you not just send `telnet localhost portnumber` down the ssh connection you made with `paramiko`? Anything you send after that will get passed to telnet until that process ends, won't it? – Simon Fraser Feb 25 '16 at 16:11
  • Thanks you :) I did not do the simpliest way :) but google-ing it seemed be not the right one. I will try in the next days (now I am on an other task). I'd like only to catch and elaborate the info transmitted after the command in telnet. – Vigmarco Feb 26 '16 at 08:01

0 Answers0