[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: ssh port forwarding



hiya,

On Sun, Nov 10, 2002 at 03:24:54AM -0600, Gerald Livingston wrote:
> On the laptop I'm using the ssh command line:
> 
> ssh root@home-machine -R 143:localhost:143

to clarify, you're doing this so you can tunnel an imap connection to
your home machine on your laptop?  if so, then you actually want to
do

ssh username@home-machine -L 1143:localhost:143

-R means forward the remote port to the local port, and -L means forward
the local port to the remote port, which is what i'm guessing you actually
want.  i get confused by this every time i have to use it.  for example,

ssh foobar@somemachine -L 2222:localhost:22

will let you connect to somemachine's ssh port by ssh'ing to localhost on 2222,
if you ever had the need to ssh-tunnel your ssh connections...

note that since imap is already running, you don't have to ssh over as root
either, as long as the source port is above 1024.

hth
--sean

Attachment: pgpA5zoQBKo3z.pgp
Description: PGP signature


Reply to: