1999-10-28 23:15:49 +00:00
|
|
|
.\" -*- nroff -*-
|
|
|
|
.\"
|
|
|
|
.\" scp.1
|
|
|
|
.\"
|
|
|
|
.\" Author: Tatu Ylonen <ylo@cs.hut.fi>
|
|
|
|
.\"
|
|
|
|
.\" Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
|
|
|
|
.\" All rights reserved
|
|
|
|
.\"
|
|
|
|
.\" Created: Sun May 7 00:14:37 1995 ylo
|
|
|
|
.\"
|
2005-03-02 01:04:16 +00:00
|
|
|
.\" $OpenBSD: scp.1,v 1.38 2005/03/01 17:19:35 jmc Exp $
|
1999-10-28 23:15:49 +00:00
|
|
|
.\"
|
|
|
|
.Dd September 25, 1999
|
|
|
|
.Dt SCP 1
|
|
|
|
.Os
|
|
|
|
.Sh NAME
|
|
|
|
.Nm scp
|
|
|
|
.Nd secure copy (remote file copy program)
|
|
|
|
.Sh SYNOPSIS
|
|
|
|
.Nm scp
|
2003-04-01 11:42:14 +00:00
|
|
|
.Bk -words
|
2003-10-15 05:50:42 +00:00
|
|
|
.Op Fl 1246BCpqrv
|
1999-10-28 23:15:49 +00:00
|
|
|
.Op Fl c Ar cipher
|
2003-10-15 05:50:42 +00:00
|
|
|
.Op Fl F Ar ssh_config
|
1999-10-28 23:15:49 +00:00
|
|
|
.Op Fl i Ar identity_file
|
2003-02-24 00:50:50 +00:00
|
|
|
.Op Fl l Ar limit
|
2001-08-15 23:25:46 +00:00
|
|
|
.Op Fl o Ar ssh_option
|
2003-10-15 05:50:42 +00:00
|
|
|
.Op Fl P Ar port
|
|
|
|
.Op Fl S Ar program
|
1999-10-28 23:15:49 +00:00
|
|
|
.Sm off
|
|
|
|
.Oo
|
2003-10-15 05:50:42 +00:00
|
|
|
.Op Ar user No @
|
1999-10-28 23:15:49 +00:00
|
|
|
.Ar host1 No :
|
|
|
|
.Oc Ns Ar file1
|
|
|
|
.Sm on
|
|
|
|
.Op Ar ...
|
|
|
|
.Sm off
|
|
|
|
.Oo
|
2003-10-15 05:50:42 +00:00
|
|
|
.Op Ar user No @
|
1999-10-28 23:15:49 +00:00
|
|
|
.Ar host2 No :
|
|
|
|
.Oc Ar file2
|
|
|
|
.Sm on
|
2003-04-01 11:42:14 +00:00
|
|
|
.Ek
|
2000-04-13 02:26:34 +00:00
|
|
|
.Sh DESCRIPTION
|
1999-10-28 23:15:49 +00:00
|
|
|
.Nm
|
2000-03-26 03:04:51 +00:00
|
|
|
copies files between hosts on a network.
|
|
|
|
It uses
|
1999-10-28 23:15:49 +00:00
|
|
|
.Xr ssh 1
|
|
|
|
for data transfer, and uses the same authentication and provides the
|
|
|
|
same security as
|
|
|
|
.Xr ssh 1 .
|
|
|
|
Unlike
|
|
|
|
.Xr rcp 1 ,
|
|
|
|
.Nm
|
|
|
|
will ask for passwords or passphrases if they are needed for
|
|
|
|
authentication.
|
|
|
|
.Pp
|
|
|
|
Any file name may contain a host and user specification to indicate
|
2000-03-26 03:04:51 +00:00
|
|
|
that the file is to be copied to/from that host.
|
|
|
|
Copies between two remote hosts are permitted.
|
1999-10-28 23:15:49 +00:00
|
|
|
.Pp
|
|
|
|
The options are as follows:
|
|
|
|
.Bl -tag -width Ds
|
2003-10-15 05:50:42 +00:00
|
|
|
.It Fl 1
|
|
|
|
Forces
|
1999-10-28 23:15:49 +00:00
|
|
|
.Nm
|
2003-10-15 05:50:42 +00:00
|
|
|
to use protocol 1.
|
|
|
|
.It Fl 2
|
|
|
|
Forces
|
|
|
|
.Nm
|
|
|
|
to use protocol 2.
|
|
|
|
.It Fl 4
|
|
|
|
Forces
|
|
|
|
.Nm
|
|
|
|
to use IPv4 addresses only.
|
|
|
|
.It Fl 6
|
|
|
|
Forces
|
|
|
|
.Nm
|
|
|
|
to use IPv6 addresses only.
|
1999-10-28 23:15:49 +00:00
|
|
|
.It Fl B
|
|
|
|
Selects batch mode (prevents asking for passwords or passphrases).
|
|
|
|
.It Fl C
|
2000-03-26 03:04:51 +00:00
|
|
|
Compression enable.
|
|
|
|
Passes the
|
1999-10-28 23:15:49 +00:00
|
|
|
.Fl C
|
|
|
|
flag to
|
|
|
|
.Xr ssh 1
|
|
|
|
to enable compression.
|
2003-10-15 05:50:42 +00:00
|
|
|
.It Fl c Ar cipher
|
|
|
|
Selects the cipher to use for encrypting the data transfer.
|
|
|
|
This option is directly passed to
|
|
|
|
.Xr ssh 1 .
|
2001-09-18 05:38:44 +00:00
|
|
|
.It Fl F Ar ssh_config
|
|
|
|
Specifies an alternative
|
|
|
|
per-user configuration file for
|
|
|
|
.Nm ssh .
|
|
|
|
This option is directly passed to
|
|
|
|
.Xr ssh 1 .
|
2003-10-15 05:50:42 +00:00
|
|
|
.It Fl i Ar identity_file
|
|
|
|
Selects the file from which the identity (private key) for RSA
|
|
|
|
authentication is read.
|
|
|
|
This option is directly passed to
|
|
|
|
.Xr ssh 1 .
|
|
|
|
.It Fl l Ar limit
|
|
|
|
Limits the used bandwidth, specified in Kbit/s.
|
|
|
|
.It Fl o Ar ssh_option
|
|
|
|
Can be used to pass options to
|
|
|
|
.Nm ssh
|
|
|
|
in the format used in
|
|
|
|
.Xr ssh_config 5 .
|
|
|
|
This is useful for specifying options
|
|
|
|
for which there is no separate
|
|
|
|
.Nm scp
|
|
|
|
command-line flag.
|
|
|
|
For full details of the options listed below, and their possible values, see
|
|
|
|
.Xr ssh_config 5 .
|
|
|
|
.Pp
|
|
|
|
.Bl -tag -width Ds -offset indent -compact
|
|
|
|
.It AddressFamily
|
|
|
|
.It BatchMode
|
|
|
|
.It BindAddress
|
|
|
|
.It ChallengeResponseAuthentication
|
|
|
|
.It CheckHostIP
|
|
|
|
.It Cipher
|
|
|
|
.It Ciphers
|
|
|
|
.It Compression
|
|
|
|
.It CompressionLevel
|
|
|
|
.It ConnectionAttempts
|
2004-05-02 23:19:03 +00:00
|
|
|
.It ConnectTimeout
|
2004-06-15 00:34:08 +00:00
|
|
|
.It ControlMaster
|
|
|
|
.It ControlPath
|
2003-10-15 05:50:42 +00:00
|
|
|
.It GlobalKnownHostsFile
|
|
|
|
.It GSSAPIAuthentication
|
|
|
|
.It GSSAPIDelegateCredentials
|
2005-03-02 01:04:16 +00:00
|
|
|
.It HashKnownHosts
|
2003-10-15 05:50:42 +00:00
|
|
|
.It Host
|
|
|
|
.It HostbasedAuthentication
|
|
|
|
.It HostKeyAlgorithms
|
|
|
|
.It HostKeyAlias
|
|
|
|
.It HostName
|
|
|
|
.It IdentityFile
|
2004-03-08 12:12:36 +00:00
|
|
|
.It IdentitiesOnly
|
2004-11-05 09:22:00 +00:00
|
|
|
.It KbdInteractiveDevices
|
2003-10-15 05:50:42 +00:00
|
|
|
.It LogLevel
|
|
|
|
.It MACs
|
|
|
|
.It NoHostAuthenticationForLocalhost
|
|
|
|
.It NumberOfPasswordPrompts
|
|
|
|
.It PasswordAuthentication
|
|
|
|
.It Port
|
|
|
|
.It PreferredAuthentications
|
|
|
|
.It Protocol
|
|
|
|
.It ProxyCommand
|
|
|
|
.It PubkeyAuthentication
|
|
|
|
.It RhostsRSAAuthentication
|
|
|
|
.It RSAAuthentication
|
2004-05-13 03:03:04 +00:00
|
|
|
.It SendEnv
|
2003-12-17 05:33:10 +00:00
|
|
|
.It ServerAliveInterval
|
|
|
|
.It ServerAliveCountMax
|
2003-10-15 05:50:42 +00:00
|
|
|
.It SmartcardDevice
|
|
|
|
.It StrictHostKeyChecking
|
2003-12-17 05:31:10 +00:00
|
|
|
.It TCPKeepAlive
|
2003-10-15 05:50:42 +00:00
|
|
|
.It UsePrivilegedPort
|
|
|
|
.It User
|
|
|
|
.It UserKnownHostsFile
|
|
|
|
.It VerifyHostKeyDNS
|
|
|
|
.El
|
1999-10-28 23:15:49 +00:00
|
|
|
.It Fl P Ar port
|
2000-03-26 03:04:51 +00:00
|
|
|
Specifies the port to connect to on the remote host.
|
|
|
|
Note that this option is written with a capital
|
1999-10-28 23:15:49 +00:00
|
|
|
.Sq P ,
|
|
|
|
because
|
|
|
|
.Fl p
|
|
|
|
is already reserved for preserving the times and modes of the file in
|
|
|
|
.Xr rcp 1 .
|
2003-10-15 05:50:42 +00:00
|
|
|
.It Fl p
|
|
|
|
Preserves modification times, access times, and modes from the
|
|
|
|
original file.
|
|
|
|
.It Fl q
|
|
|
|
Disables the progress meter.
|
|
|
|
.It Fl r
|
|
|
|
Recursively copy entire directories.
|
2000-09-05 02:34:53 +00:00
|
|
|
.It Fl S Ar program
|
|
|
|
Name of
|
|
|
|
.Ar program
|
2000-10-14 05:23:11 +00:00
|
|
|
to use for the encrypted connection.
|
|
|
|
The program must understand
|
2000-08-23 00:46:23 +00:00
|
|
|
.Xr ssh 1
|
|
|
|
options.
|
2003-10-15 05:50:42 +00:00
|
|
|
.It Fl v
|
|
|
|
Verbose mode.
|
|
|
|
Causes
|
2000-01-14 04:45:46 +00:00
|
|
|
.Nm
|
2003-10-15 05:50:42 +00:00
|
|
|
and
|
|
|
|
.Xr ssh 1
|
|
|
|
to print debugging messages about their progress.
|
|
|
|
This is helpful in
|
|
|
|
debugging connection, authentication, and configuration problems.
|
2000-07-11 07:31:38 +00:00
|
|
|
.El
|
2002-02-05 01:16:15 +00:00
|
|
|
.Sh DIAGNOSTICS
|
|
|
|
.Nm
|
|
|
|
exits with 0 on success or >0 if an error occurred.
|
1999-10-28 23:15:49 +00:00
|
|
|
.Sh SEE ALSO
|
|
|
|
.Xr rcp 1 ,
|
2001-02-04 12:20:18 +00:00
|
|
|
.Xr sftp 1 ,
|
1999-10-28 23:15:49 +00:00
|
|
|
.Xr ssh 1 ,
|
|
|
|
.Xr ssh-add 1 ,
|
|
|
|
.Xr ssh-agent 1 ,
|
|
|
|
.Xr ssh-keygen 1 ,
|
2002-06-23 00:34:37 +00:00
|
|
|
.Xr ssh_config 5 ,
|
1999-10-28 23:15:49 +00:00
|
|
|
.Xr sshd 8
|
2003-06-11 12:04:39 +00:00
|
|
|
.Sh HISTORY
|
|
|
|
.Nm
|
|
|
|
is based on the
|
|
|
|
.Xr rcp 1
|
|
|
|
program in BSD source code from the Regents of the University of
|
|
|
|
California.
|
|
|
|
.Sh AUTHORS
|
|
|
|
.An Timo Rinne Aq tri@iki.fi
|
|
|
|
.An Tatu Ylonen Aq ylo@cs.hut.fi
|