Solved

how to do a quick tunnel with ssh

Posted on 2011-02-16
2
419 Views
Last Modified: 2012-05-11
I have a jumpoff box and just want to scp files from a to c, not from a, to the jumpoff and then to c.  

Also I need to make suure the tunnel goes away when I leave.

0
Comment
Question by:TIMFOX123
2 Comments
 
LVL 6

Accepted Solution

by:
de2Zotjes earned 500 total points
ID: 34915402
If it doesn't matter to you to logon to host a first:
You can use netcat/nc to pipe/tunnel all the traffic you put to jumpoff from a  further onto c

on host a put this in .ssh/config:
Host c
  ProxyCommand /usr/bin/ssh -q -A -x jumpoff nc -w30 <address of c> 22

Open in new window

You need to make sure that the user executing this can logon to jumpoff (from a) without user intervention.

The proxycommand causes ssh to first issue the commands in there and connect stdin/stdout of the sshsession to stdin/stdout of the proxycommand.
The command here will setup a session to jumpoff and execute netcat on jumphost, connecting in and out to netcat.
Tis solution is somewhat expensive as the traffic is double encrypted on the first leg (a to jumpoff)
0
 

Author Closing Comment

by:TIMFOX123
ID: 34917195
great answer

thx
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

I have seen several blogs and forum entries elsewhere state that because NTFS volumes do not support linux ownership or permissions, they cannot be used for anonymous ftp upload through the vsftpd program.   IT can be done and here's how to get i…
​Being a Managed Services Provider (MSP) has presented you  with challenges in the past— and by meeting those challenges you’ve reaped the rewards of success.  In 2014, challenges and rewards remain; but as the Internet and business environment evol…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…
When you create an app prototype with Adobe XD, you can insert system screens -- sharing or Control Center, for example -- with just a few clicks. This video shows you how. You can take the full course on Experts Exchange at http://bit.ly/XDcourse.

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now