]>
Commit | Line | Data |
---|---|---|
0426a3b4 | 1 | .\" $OpenBSD: sftp.1,v 1.5 2001/02/07 18:10:39 stevesk Exp $ |
61e96248 | 2 | .\" |
3 | .\" Copyright (c) 2001 Damien Miller. All rights reserved. | |
4 | .\" | |
5 | .\" Redistribution and use in source and binary forms, with or without | |
6 | .\" modification, are permitted provided that the following conditions | |
7 | .\" are met: | |
8 | .\" 1. Redistributions of source code must retain the above copyright | |
9 | .\" notice, this list of conditions and the following disclaimer. | |
10 | .\" 2. Redistributions in binary form must reproduce the above copyright | |
11 | .\" notice, this list of conditions and the following disclaimer in the | |
12 | .\" documentation and/or other materials provided with the distribution. | |
13 | .\" | |
14 | .\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR | |
15 | .\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES | |
16 | .\" OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. | |
17 | .\" IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, | |
18 | .\" INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT | |
19 | .\" NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | |
20 | .\" DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | |
21 | .\" THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | |
22 | .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF | |
23 | .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | |
24 | .\" | |
25 | .Dd Febuary 4, 2001 | |
26 | .Dt SFTP 1 | |
27 | .Os | |
28 | .Sh NAME | |
29 | .Nm sftp | |
30 | .Nd Secure file tranfer program | |
31 | .Sh SYNOPSIS | |
32 | .Nm sftp | |
0426a3b4 | 33 | .Op Fl vC |
61e96248 | 34 | .Op Fl o Ar ssh_option |
35 | .Op Ar hostname | user@hostname | |
36 | .Sh DESCRIPTION | |
37 | .Nm | |
38 | is an interactive file transfer program, similar to | |
39 | .Xr ftp 1 , | |
40 | which performs all operations over an encrypted | |
41 | .Xr ssh 1 | |
42 | transport. | |
43 | It may also use many features of ssh, such as public key authentication and | |
44 | compression. | |
45 | .Nm | |
46 | connects and logs into the specified | |
0426a3b4 | 47 | .Ar hostname , |
61e96248 | 48 | then enters an interactive command mode. |
49 | .Pp | |
50 | The options are as follows: | |
51 | .Bl -tag -width Ds | |
0426a3b4 | 52 | .It Fl v |
53 | Raise logging level. This option is also passed to ssh. | |
61e96248 | 54 | .It Fl C |
55 | Enables compression (via ssh's | |
56 | .Fl C | |
57 | flag) | |
61e96248 | 58 | .It Fl o Ar ssh_option |
59 | Specify an option to be directly passed to | |
60 | .Xr ssh 1 . | |
61 | .El | |
62 | .Sh INTERACTIVE COMMANDS | |
0426a3b4 | 63 | Once in interactive mode, |
64 | .Nm | |
61e96248 | 65 | understands a set of commands similar to those of |
66 | .Xr ftp 1 . | |
67 | Commands are case insensitive. | |
68 | .Bl -tag -width Ds | |
0426a3b4 | 69 | .It Ic cd Ar path |
61e96248 | 70 | Change remote directory to |
0426a3b4 | 71 | .Ar path . |
72 | .It Ic lcd Ar path | |
61e96248 | 73 | Change local directory to |
0426a3b4 | 74 | .Ar path . |
75 | .It Ic chgrp Ar grp Ar path | |
61e96248 | 76 | Change group of file |
0426a3b4 | 77 | .Ar path |
78 | to | |
61e96248 | 79 | .Ar grp . |
80 | .Ar grp | |
0426a3b4 | 81 | must be a numeric GID. |
82 | .It Ic chmod Ar mode Ar path | |
61e96248 | 83 | Change permissions of file |
0426a3b4 | 84 | .Ar path |
85 | to | |
86 | .Ar mode . | |
87 | .It Ic chown Ar own Ar path | |
61e96248 | 88 | Change owner of file |
0426a3b4 | 89 | .Ar path |
90 | to | |
61e96248 | 91 | .Ar own . |
92 | .Ar own | |
93 | must be a numeric UID. | |
0426a3b4 | 94 | .It Ic help |
95 | Display help text. | |
96 | .It Ic get Ar remote-path Op Ar local-path | |
61e96248 | 97 | Retrieve the |
0426a3b4 | 98 | .Ar remote-path |
61e96248 | 99 | and store it on the local machine. |
100 | If the local | |
0426a3b4 | 101 | path name is not specified, it is given the same name it has on the |
61e96248 | 102 | remote machine. |
0426a3b4 | 103 | .It Ic lls Op Ar ls-options Op Ar path |
61e96248 | 104 | Display local directory listing of either |
105 | .Ar path | |
106 | or current directory if | |
107 | .Ar path | |
0426a3b4 | 108 | is not specified. |
109 | .It Ic lmkdir Ar path | |
61e96248 | 110 | Create local directory specified by |
0426a3b4 | 111 | .Ar path . |
112 | .It Ic lpwd | |
113 | Print local working directory. | |
114 | .It Ic ls Op Ar path | |
61e96248 | 115 | Display remote directory listing of either |
116 | .Ar path | |
0426a3b4 | 117 | or current directory if |
118 | .Ar path | |
119 | is not specified. | |
120 | .It Ic lumask Ar umask | |
61e96248 | 121 | Set local umask to |
0426a3b4 | 122 | .Ar umask . |
123 | .It Ic mkdir Ar path | |
61e96248 | 124 | Create remote directory specified by |
0426a3b4 | 125 | .Ar path . |
126 | .It Ic put Ar local-path Op Ar remote-path | |
61e96248 | 127 | Upload |
0426a3b4 | 128 | .Ar local-path |
129 | and store it on the remote machine. If the remote path name is not specified, | |
61e96248 | 130 | it is given the same name it has on the local machine. |
0426a3b4 | 131 | .It Ic pwd |
132 | Display remote working directory. | |
133 | .It Ic exit | |
134 | Quit sftp. | |
135 | .It Ic quit | |
136 | Quit sftp. | |
137 | .It Ic rename Ar oldpath Ar newpath | |
61e96248 | 138 | Rename remote file from |
139 | .Ar oldpath | |
140 | to | |
0426a3b4 | 141 | .Ar newpath . |
142 | .It Ic rmdir Ar path | |
61e96248 | 143 | Remove remote directory specified by |
0426a3b4 | 144 | .Ar path . |
145 | .It Ic rm Ar path | |
61e96248 | 146 | Delete remote file specified by |
0426a3b4 | 147 | .Ar path . |
61e96248 | 148 | .It Ic ! Ar command |
149 | Execute | |
150 | .Ar command | |
0426a3b4 | 151 | in local shell. |
61e96248 | 152 | .It Ic ! |
0426a3b4 | 153 | Escape to local shell. |
154 | .It Ic ? | |
155 | Synonym for help. | |
156 | .El | |
61e96248 | 157 | .Sh AUTHORS |
158 | Damien Miller <djm@mindrot.org> | |
159 | .Sh SEE ALSO | |
160 | .Xr ssh 1 , | |
161 | .Xr ssh-add 1 , | |
162 | .Xr ssh-keygen 1 , | |
0426a3b4 | 163 | .Xr sshd 8 , |
164 | .Xr scp 1 | |
165 |