blob: 51ef34c88e157f7325ebd39f8c31b745547dad4e [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 Miller7b28dc52000-09-05 13:34:53 +110012.\" $Id: scp.1,v 1.10 2000/09/05 02:34:54 djm 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 Miller7b28dc52000-09-05 13:34:53 +110023.Op Fl S Ar program
Damien Miller32aa1441999-10-29 09:15:49 +100024.Op Fl P Ar port
25.Op Fl c Ar cipher
26.Op Fl i Ar identity_file
27.Sm off
28.Oo
29.Op Ar user@
30.Ar host1 No :
31.Oc Ns Ar file1
32.Sm on
33.Op Ar ...
34.Sm off
35.Oo
36.Op Ar user@
37.Ar host2 No :
38.Oc Ar file2
39.Sm on
Damien Miller22c77262000-04-13 12:26:34 +100040.Sh DESCRIPTION
Damien Miller32aa1441999-10-29 09:15:49 +100041.Nm
Damien Miller450a7a12000-03-26 13:04:51 +100042copies files between hosts on a network.
43It uses
Damien Miller32aa1441999-10-29 09:15:49 +100044.Xr ssh 1
45for data transfer, and uses the same authentication and provides the
46same security as
47.Xr ssh 1 .
48Unlike
49.Xr rcp 1 ,
50.Nm
51will ask for passwords or passphrases if they are needed for
52authentication.
53.Pp
54Any file name may contain a host and user specification to indicate
Damien Miller450a7a12000-03-26 13:04:51 +100055that the file is to be copied to/from that host.
56Copies between two remote hosts are permitted.
Damien Miller32aa1441999-10-29 09:15:49 +100057.Pp
58The options are as follows:
59.Bl -tag -width Ds
60.It Fl c Ar cipher
Damien Miller450a7a12000-03-26 13:04:51 +100061Selects the cipher to use for encrypting the data transfer.
62This option is directly passed to
Damien Miller32aa1441999-10-29 09:15:49 +100063.Xr ssh 1 .
64.It Fl i Ar identity_file
65Selects the file from which the identity (private key) for RSA
Damien Miller450a7a12000-03-26 13:04:51 +100066authentication is read.
67This option is directly passed to
Damien Miller32aa1441999-10-29 09:15:49 +100068.Xr ssh 1 .
69.It Fl p
70Preserves modification times, access times, and modes from the
71original file.
72.It Fl r
73Recursively copy entire directories.
74.It Fl v
Damien Miller450a7a12000-03-26 13:04:51 +100075Verbose mode.
76Causes
Damien Miller32aa1441999-10-29 09:15:49 +100077.Nm
Damien Miller22c77262000-04-13 12:26:34 +100078and
Damien Miller32aa1441999-10-29 09:15:49 +100079.Xr ssh 1
Damien Miller450a7a12000-03-26 13:04:51 +100080to print debugging messages about their progress.
81This is helpful in
Damien Miller32aa1441999-10-29 09:15:49 +100082debugging connection, authentication, and configuration problems.
83.It Fl B
84Selects batch mode (prevents asking for passwords or passphrases).
85.It Fl q
86Disables the progress meter.
87.It Fl C
Damien Miller450a7a12000-03-26 13:04:51 +100088Compression enable.
89Passes the
Damien Miller32aa1441999-10-29 09:15:49 +100090.Fl C
91flag to
92.Xr ssh 1
93to enable compression.
94.It Fl P Ar port
Damien Miller450a7a12000-03-26 13:04:51 +100095Specifies the port to connect to on the remote host.
96Note that this option is written with a capital
Damien Miller32aa1441999-10-29 09:15:49 +100097.Sq P ,
98because
99.Fl p
100is already reserved for preserving the times and modes of the file in
101.Xr rcp 1 .
Damien Miller7b28dc52000-09-05 13:34:53 +1100102.It Fl S Ar program
103Name of
104.Ar program
105to use for the encrypted connection. The program must understand
Damien Millerad833b32000-08-23 10:46:23 +1000106.Xr ssh 1
107options.
Damien Miller34132e52000-01-14 15:45:46 +1100108.It Fl 4
109Forces
110.Nm
111to use IPv4 addresses only.
112.It Fl 6
113Forces
114.Nm
115to use IPv6 addresses only.
Damien Miller37023962000-07-11 17:31:38 +1000116.El
Damien Miller32aa1441999-10-29 09:15:49 +1000117.Sh AUTHORS
118Timo Rinne <tri@iki.fi> and Tatu Ylonen <ylo@cs.hut.fi>
119.Sh HISTORY
120.Nm
121is based on the
122.Xr rcp 1
123program in BSD source code from the Regents of the University of
124California.
125.Sh SEE ALSO
126.Xr rcp 1 ,
127.Xr ssh 1 ,
128.Xr ssh-add 1 ,
129.Xr ssh-agent 1 ,
130.Xr ssh-keygen 1 ,
131.Xr sshd 8