Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 Jul 2001 13:59:54 -0600 (MDT)
From:      Brett Glass <brett@lariat.org>
To:        security@freebsd.org
Subject:   Piping and scripts with scp
Message-ID:  <200107181959.NAA06459@lariat.org>

next in thread | raw e-mail | index | archive | help
I need to create a script that deposits the output of a program in a file on a
remote host. I'd like to do this over an encrypted connection, so I'd like to
use scp for this purpose.  The script will need to execute via cron and run
unattended, and I'm limited to the SSH-1 protocol for the moment (though I
intend to move to SSH-2 when all the hosts can handle it).

Trouble is, I cannot seem to find options for scp that will allow me
to (a) pipe data into it for placement in the remote file; or
(b) supply a password -- kept only in the script, which cannot be
read except by root -- in advance rather than manually at the console.
(Yes, I could generate and use RSA keys, but since anyone who could
view the script will have broken root, he or she could also get at
the private key anyway... so there's no additional security in this.)
Help from someone experienced with scp and ssh would be appreciated.

--Brett Glass


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-security" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200107181959.NAA06459>