From owner-freebsd-questions@FreeBSD.ORG Fri May 9 03:01:21 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 268D8106564A for ; Fri, 9 May 2008 03:01:21 +0000 (UTC) (envelope-from peter@boosten.org) Received: from smtpq2.groni1.gr.home.nl (smtpq2.groni1.gr.home.nl [213.51.130.201]) by mx1.freebsd.org (Postfix) with ESMTP id 68F208FC21 for ; Fri, 9 May 2008 03:01:20 +0000 (UTC) (envelope-from peter@boosten.org) Received: from [213.51.130.189] (port=43487 helo=smtp2.groni1.gr.home.nl) by smtpq2.groni1.gr.home.nl with esmtp (Exim 4.60) (envelope-from ) id 1JuIrH-0007MF-2n for freebsd-questions@freebsd.org; Fri, 09 May 2008 05:01:19 +0200 Received: from cp268254-a.landg1.lb.home.nl ([84.25.65.88]:5003 helo=ra.egypt.nl) by smtp2.groni1.gr.home.nl with esmtp (Exim 4.60) (envelope-from ) id 1JuIrG-0004py-Bp for freebsd-questions@freebsd.org; Fri, 09 May 2008 05:01:19 +0200 Received: from [127.0.0.1] (xp.egypt.nl [192.168.13.35]) by ra.egypt.nl (Postfix) with ESMTP id E5FE539803 for ; Fri, 9 May 2008 05:01:16 +0200 (CEST) Message-ID: <4823BE7B.2050806@boosten.org> Date: Fri, 09 May 2008 05:01:15 +0200 From: Peter Boosten User-Agent: Thunderbird 2.0.0.14 (Windows/20080421) MIME-Version: 1.0 To: freebsd-questions@freebsd.org References: <200805060931.18936.beech@freebsd.org> <20080506173912.GB85015@Grumpy.DynDNS.org> <200805060959.28509.beech@freebsd.org> <48229099.5030004@boosten.org> <20080508224235.GA87584@devil.mutu.us> In-Reply-To: <20080508224235.GA87584@devil.mutu.us> X-Enigmail-Version: 0.95.6 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Antivirus: avast! (VPS 080508-0, 05/08/2008), Outbound message X-Antivirus-Status: Clean X-Spam-Score: -0.0 (/) Subject: Re: [SSHd] Increasing wait time? X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 09 May 2008 03:01:42 -0000 Valeriu Mutu wrote: > On Thu, May 08, 2008 at 07:33:13AM +0200, Peter Boosten wrote: >> Vince Sabio wrote: >>> Note if you choose to do this: scp'ing files becomes a four-step process >>> (i.e., scp file(s) to intermediate server, log in to intermediate server, >>> scp to destination server, delete file(s) from intermediate server). Still >>> worth it, though. >> Never thought of port forwarding? >> >> Peter > > Exactly. > > Following Peter's idea and assuming that public key authentication is setup, the tunnel could be setup as easy as: > ssh -f -L localhost:3333:localhost:4444 userA@machineA "ssh -f -L localhost:4444:localhost:22 userB@machineB sleep 120" > > In this case, we setup a tunnel through machineA to machineB. No, I was more thinking of: ssh -L 4444:your.own.host:22 user@your.friends.host and then open a new shell: scp -P 4444 the-file-you-want-to-copy user@localhost: This works easiest with agent forwarding, but I guess any authentication will do. Peter -- http://www.boosten.org