brockgr / csshx

Automatically exported from code.google.com/p/csshx
434 stars 77 forks source link

Telnet protocol support #59

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
In addition to supporting SSH, add support for a flag allowing multiple 
terminal control of hosts over telnet.

Original issue reported on code.google.com by maxim.po...@gmail.com on 1 Oct 2013 at 3:41

GoogleCodeExporter commented 9 years ago
Never mind, just realized I can do this with the --ssh option like so. Thanks!

csshx --ssh telnet [host pattern]

Original comment by maxim.po...@gmail.com on 1 Oct 2013 at 3:46

GoogleCodeExporter commented 9 years ago
You know if your able to have different port number for say a list of 4 
sessions ?

Original comment by Ritzt...@gmail.com on 4 Feb 2014 at 3:32

GoogleCodeExporter commented 9 years ago
I've never tried that myself but based on the host pattern in the manual it 
would appear that this is possible:

csshX [--login username] [--config filename] _[user@host1[:port] 
[[user@]host2[:port]] .. ]

Just put the port number after each hostname with a colon between the two.

Original comment by maxim.po...@gmail.com on 4 Feb 2014 at 4:41

sudoritz commented 4 years ago

Here is a mini workaround if Telnet has a different port

My use case is to utilize with EVE-NG / GNS3 labs so when we reverse console they are telnet mode to gear.

i was able to overcome this by doing a wrapper for another script and calling csshX to that script

csshx --ssh tnet [192.168.4.14:32741 192.168.4.14:32742 etc.. etc..]

because it comes in as this and uses -p option where default telnet just needs a space as these are the Arguments passed to the bash script. so i reversed those and pass them in a mini tnet script

[1]= -p [2]= 32741 [3]= 192.168.4.14

cat /usr/local/bin/tnet
telnet $3 $2