Merge branch 'vendor/OPENSSL'
[dragonfly.git] / bin / rcp / rcp.1
1 .\" Copyright (c) 1983, 1990, 1993
2 .\"     The Regents of the University of California.  All rights reserved.
3 .\"
4 .\" Redistribution and use in source and binary forms, with or without
5 .\" modification, are permitted provided that the following conditions
6 .\" are met:
7 .\" 1. Redistributions of source code must retain the above copyright
8 .\"    notice, this list of conditions and the following disclaimer.
9 .\" 2. Redistributions in binary form must reproduce the above copyright
10 .\"    notice, this list of conditions and the following disclaimer in the
11 .\"    documentation and/or other materials provided with the distribution.
12 .\" 3. All advertising materials mentioning features or use of this software
13 .\"    must display the following acknowledgement:
14 .\"     This product includes software developed by the University of
15 .\"     California, Berkeley and its contributors.
16 .\" 4. Neither the name of the University nor the names of its contributors
17 .\"    may be used to endorse or promote products derived from this software
18 .\"    without specific prior written permission.
19 .\"
20 .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
21 .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
22 .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
23 .\" ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
24 .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
25 .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
26 .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
27 .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
28 .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
29 .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
30 .\" SUCH DAMAGE.
31 .\"
32 .\"     @(#)rcp.1       8.1 (Berkeley) 5/31/93
33 .\" $FreeBSD: src/bin/rcp/rcp.1,v 1.9.2.6 2002/08/16 20:06:34 ume Exp $
34 .\" $DragonFly: src/bin/rcp/rcp.1,v 1.2 2003/06/17 04:22:50 dillon Exp $
35 .\"
36 .Dd May 31, 1993
37 .Dt RCP 1
38 .Os
39 .Sh NAME
40 .Nm rcp
41 .Nd remote file copy
42 .Sh SYNOPSIS
43 .Nm
44 .Op Fl 46Kpx
45 .Op Fl k Ar realm
46 .Ar file1 file2
47 .Nm
48 .Op Fl 46Kprx
49 .Op Fl k Ar realm
50 .Ar
51 .Ar directory
52 .Sh DESCRIPTION
53 The
54 .Nm
55 utility copies files between machines.  Each
56 .Ar file
57 or
58 .Ar directory
59 argument is either a remote file name of the
60 form
61 .Dq rname@rhost:path ,
62 or a local file name (containing no `:' characters,
63 or a `/' before any `:'s).
64 .Pp
65 The following options are available:
66 .Bl -tag -width indent
67 .It Fl 4
68 Use IPv4 addresses only.
69 .It Fl 6
70 Use IPv6 addresses only.
71 .It Fl K
72 Turn off all Kerberos authentication.
73 .It Fl k
74 Request
75 .Nm
76 to obtain tickets
77 for the remote host in realm
78 .Ar realm
79 instead of the remote host's realm as determined by
80 .Xr krb_realmofhost 3 .
81 .It Fl p
82 Cause
83 .Nm
84 to attempt to preserve (duplicate) in its copies the modification
85 times and modes of the source files, ignoring the
86 .Ar umask  .
87 By default, the mode and owner of
88 .Ar file2
89 are preserved if it already existed; otherwise the mode of the source file
90 modified by the
91 .Xr umask  2
92 on the destination host is used.
93 .It Fl r
94 If any of the source files are directories,
95 .Nm
96 copies each subtree rooted at that name; in this case
97 the destination must be a directory.
98 .It Fl x
99 Turn on
100 .Tn DES
101 encryption for all data passed by
102 .Nm .
103 This may impact response time and
104 .Tn CPU
105 utilization, but provides
106 increased security.
107 .El
108 .Pp
109 If
110 .Ar path
111 is not a full path name, it is interpreted relative to
112 the login directory of the specified user
113 .Ar ruser
114 on
115 .Ar rhost  ,
116 or your current user name if no other remote user name is specified.
117 A
118 .Ar path
119 on a remote host may be quoted (using \e, ", or \(aa)
120 so that the metacharacters are interpreted remotely.
121 .Pp
122 The
123 .Nm
124 utility does not prompt for passwords; it performs remote execution
125 via
126 .Xr rsh  1  ,
127 and requires the same authorization.
128 .Pp
129 The
130 .Nm
131 utility handles third party copies, where neither source nor target files
132 are on the current machine.
133 .Sh FILES
134 .Bl -tag -width /etc/auth.conf -compact
135 .It Pa /etc/auth.conf
136 configure authentication services
137 .El
138 .Sh SEE ALSO
139 .Xr cp 1 ,
140 .Xr ftp 1 ,
141 .Xr rlogin 1 ,
142 .Xr rsh 1 ,
143 .Xr auth.conf 5 ,
144 .Xr hosts.equiv 5
145 .Sh HISTORY
146 The
147 .Nm
148 command appeared in
149 .Bx 4.2 .
150 The version of
151 .Nm
152 described here
153 has been reimplemented with Kerberos in
154 .Bx 4.3 Reno .
155 .Sh BUGS
156 Doesn't detect all cases where the target of a copy might
157 be a file in cases where only a directory should be legal.
158 .Pp
159 Is confused by any output generated by commands in a
160 .Pa \&.login ,
161 .Pa \&.profile ,
162 or
163 .Pa \&.cshrc
164 file on the remote host.
165 .Pp
166 The destination user and hostname may have to be specified as
167 .Dq rhost.rname
168 when the destination machine is running the
169 .Bx 4.2
170 version of
171 .Nm .