blob: c90943a06fd051e24265973b7cec98ed6698efa4 [file] [log] [blame]
Damien Miller32aa1441999-10-29 09:15:49 +10001.\" -*- nroff -*-
2.\"
3.\" scp.1
4.\"
5.\" Author: Tatu Ylonen <ylo@cs.hut.fi>
6.\"
7.\" Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland
8.\" All rights reserved
9.\"
10.\" Created: Sun May 7 00:14:37 1995 ylo
11.\"
Damien Miller22c77262000-04-13 12:26:34 +100012.\" $Id: scp.1,v 1.7 2000/04/13 02:26:37 damien Exp $
Damien Miller32aa1441999-10-29 09:15:49 +100013.\"
14.Dd September 25, 1999
15.Dt SCP 1
16.Os
17.Sh NAME
18.Nm scp
19.Nd secure copy (remote file copy program)
20.Sh SYNOPSIS
21.Nm scp
Damien Miller34132e52000-01-14 15:45:46 +110022.Op Fl pqrvC46
Damien Miller32aa1441999-10-29 09:15:49 +100023.Op Fl P Ar port
24.Op Fl c Ar cipher
25.Op Fl i Ar identity_file
26.Sm off
27.Oo
28.Op Ar user@
29.Ar host1 No :
30.Oc Ns Ar file1
31.Sm on
32.Op Ar ...
33.Sm off
34.Oo
35.Op Ar user@
36.Ar host2 No :
37.Oc Ar file2
38.Sm on
Damien Miller22c77262000-04-13 12:26:34 +100039.Sh DESCRIPTION
Damien Miller32aa1441999-10-29 09:15:49 +100040.Nm
Damien Miller450a7a12000-03-26 13:04:51 +100041copies files between hosts on a network.
42It uses
Damien Miller32aa1441999-10-29 09:15:49 +100043.Xr ssh 1
44for data transfer, and uses the same authentication and provides the
45same security as
46.Xr ssh 1 .
47Unlike
48.Xr rcp 1 ,
49.Nm
50will ask for passwords or passphrases if they are needed for
51authentication.
52.Pp
53Any file name may contain a host and user specification to indicate
Damien Miller450a7a12000-03-26 13:04:51 +100054that the file is to be copied to/from that host.
55Copies between two remote hosts are permitted.
Damien Miller32aa1441999-10-29 09:15:49 +100056.Pp
57The options are as follows:
58.Bl -tag -width Ds
59.It Fl c Ar cipher
Damien Miller450a7a12000-03-26 13:04:51 +100060Selects the cipher to use for encrypting the data transfer.
61This option is directly passed to
Damien Miller32aa1441999-10-29 09:15:49 +100062.Xr ssh 1 .
63.It Fl i Ar identity_file
64Selects the file from which the identity (private key) for RSA
Damien Miller450a7a12000-03-26 13:04:51 +100065authentication is read.
66This option is directly passed to
Damien Miller32aa1441999-10-29 09:15:49 +100067.Xr ssh 1 .
68.It Fl p
69Preserves modification times, access times, and modes from the
70original file.
71.It Fl r
72Recursively copy entire directories.
73.It Fl v
Damien Miller450a7a12000-03-26 13:04:51 +100074Verbose mode.
75Causes
Damien Miller32aa1441999-10-29 09:15:49 +100076.Nm
Damien Miller22c77262000-04-13 12:26:34 +100077and
Damien Miller32aa1441999-10-29 09:15:49 +100078.Xr ssh 1
Damien Miller450a7a12000-03-26 13:04:51 +100079to print debugging messages about their progress.
80This is helpful in
Damien Miller32aa1441999-10-29 09:15:49 +100081debugging connection, authentication, and configuration problems.
82.It Fl B
83Selects batch mode (prevents asking for passwords or passphrases).
84.It Fl q
85Disables the progress meter.
86.It Fl C
Damien Miller450a7a12000-03-26 13:04:51 +100087Compression enable.
88Passes the
Damien Miller32aa1441999-10-29 09:15:49 +100089.Fl C
90flag to
91.Xr ssh 1
92to enable compression.
93.It Fl P Ar port
Damien Miller450a7a12000-03-26 13:04:51 +100094Specifies the port to connect to on the remote host.
95Note that this option is written with a capital
Damien Miller32aa1441999-10-29 09:15:49 +100096.Sq P ,
97because
98.Fl p
99is already reserved for preserving the times and modes of the file in
100.Xr rcp 1 .
Damien Miller34132e52000-01-14 15:45:46 +1100101.It Fl 4
102Forces
103.Nm
104to use IPv4 addresses only.
105.It Fl 6
106Forces
107.Nm
108to use IPv6 addresses only.
Damien Miller32aa1441999-10-29 09:15:49 +1000109.Sh AUTHORS
110Timo Rinne <tri@iki.fi> and Tatu Ylonen <ylo@cs.hut.fi>
111.Sh HISTORY
112.Nm
113is based on the
114.Xr rcp 1
115program in BSD source code from the Regents of the University of
116California.
117.Sh SEE ALSO
118.Xr rcp 1 ,
119.Xr ssh 1 ,
120.Xr ssh-add 1 ,
121.Xr ssh-agent 1 ,
122.Xr ssh-keygen 1 ,
123.Xr sshd 8