unable to connect to Yellow Dog Linux machine through telnet

nathan r. hruby yellowdog-general@lists.terrasoftsolutions.com
Fri Nov 21 08:17:02 2003


On Fri, 21 Nov 2003, R. Hirschfeld wrote:

> 
> If you require telnet because e.g. some application knows how to act
> as a telnet client but not as an ssh client, you can get the security
> benefits of ssh by using its tunneling feature.  For example, if you
> connect to the destination machine with
> 
>   ssh -fNL 2323:localhost:23 user@host.domain
> 
> you can then do
> 
>   telnet localhost 2323
> 

This is an awesome solution, but sometimes it's nice to explain what these
commands do, to give them context and perhaps some additional
enlightenment..  ssh port forwarding and remote command execution is
always a bit odd.

The above ssh command means "Hey, ssh, connect to host.domain as user, but
don't execute any commands on the other machine (-N) just forward port
2323 on this machine's localhost interface to the other machine's port 23
(-L 2323:localhost:23) and after you ask for the password and setup the
port forwarding, go to the background to give the current terminal back to
the user (-f)"

Once you get your prompt back you can then use the above telnet command 
which will connect to your local computer's lo interface on port 2323, 
which ssh has already forwarded to the remote computer and redirected to 
the telnet daemon.  Each endpoint (eg, your loopback connection and the 
loopback connection on the other machine) are insecure, but the connection 
across the real network are encrypted.

Also another benefit (or testament to the utility of ssh): If you're on a
dial-up connection or other slow link, you can add the -C option to the
above ssh command to make the tunnel use compression, and your telnet
session will take advantage of that transparently as ssh will handle the 
compression.

HTH someone at some point :)

-n
-- 
-------------------------------------------
nathan hruby <nhruby@uga.edu>
uga enterprise information technology services
production systems support
metaphysically wrinkle-free
-------------------------------------------