[BACK]Return to sftp.1 CVS log [TXT][DIR] Up to [local] / src / usr.bin / ssh

Annotation of src/usr.bin/ssh/sftp.1, Revision 1.10

1.10    ! deraadt     1: .\" $OpenBSD: sftp.1,v 1.9 2001/03/02 18:54:31 deraadt Exp $
1.1       djm         2: .\"
1.9       deraadt     3: .\" Copyright (c) 2001 Damien Miller.  All rights reserved.
1.1       djm         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
1.8       reinhard   30: .Nd Secure file transfer program
1.1       djm        31: .Sh SYNOPSIS
                     32: .Nm sftp
1.3       deraadt    33: .Op Fl vC
1.10    ! deraadt    34: .Op Fl b Ar batchfile
1.1       djm        35: .Op Fl o Ar ssh_option
                     36: .Op Ar hostname | user@hostname
                     37: .Sh DESCRIPTION
                     38: .Nm
                     39: is an interactive file transfer program, similar to
                     40: .Xr ftp 1 ,
                     41: which performs all operations over an encrypted
                     42: .Xr ssh 1
                     43: transport.
                     44: It may also use many features of ssh, such as public key authentication and
                     45: compression.
                     46: .Nm
                     47: connects and logs into the specified
1.5       stevesk    48: .Ar hostname ,
1.1       djm        49: then enters an interactive command mode.
                     50: .Pp
                     51: The options are as follows:
                     52: .Bl -tag -width Ds
1.5       stevesk    53: .It Fl v
                     54: Raise logging level. This option is also passed to ssh.
1.1       djm        55: .It Fl C
                     56: Enables compression (via ssh's
                     57: .Fl C
                     58: flag)
1.10    ! deraadt    59: .It Fl b Ar batchfile
        !            60: Batch mode reads a series of commands from an input
        !            61: .Fn batchfile
        !            62: instead of
        !            63: .Fn stdin .
        !            64: Since it lacks user interaction it should be used in conjuction with a
        !            65: non-interactive authentication.  Sftp will abort if any of the following
        !            66: commands fail:
        !            67: .Pa get, put, rename, rm, mkdir, chdir, lchdir
        !            68: and
        !            69: .Pa lmkdir.
1.1       djm        70: .It Fl o Ar ssh_option
                     71: Specify an option to be directly passed to
                     72: .Xr ssh 1 .
                     73: .El
                     74: .Sh INTERACTIVE COMMANDS
1.2       djm        75: Once in interactive mode,
                     76: .Nm
1.1       djm        77: understands a set of commands similar to those of
                     78: .Xr ftp 1 .
1.6       djm        79: Commands are case insensitive and pathnames may be enclosed in quotes if they
                     80: contain spaces.
1.1       djm        81: .Bl -tag -width Ds
1.3       deraadt    82: .It Ic cd Ar path
1.1       djm        83: Change remote directory to
1.3       deraadt    84: .Ar path .
                     85: .It Ic lcd Ar path
1.1       djm        86: Change local directory to
1.3       deraadt    87: .Ar path .
                     88: .It Ic chgrp Ar grp Ar path
1.1       djm        89: Change group of file
1.5       stevesk    90: .Ar path
                     91: to
1.1       djm        92: .Ar grp .
                     93: .Ar grp
1.5       stevesk    94: must be a numeric GID.
1.3       deraadt    95: .It Ic chmod Ar mode Ar path
1.1       djm        96: Change permissions of file
1.5       stevesk    97: .Ar path
                     98: to
1.3       deraadt    99: .Ar mode .
                    100: .It Ic chown Ar own Ar path
1.1       djm       101: Change owner of file
1.5       stevesk   102: .Ar path
                    103: to
1.1       djm       104: .Ar own .
                    105: .Ar own
                    106: must be a numeric UID.
1.3       deraadt   107: .It Ic help
                    108: Display help text.
1.7       djm       109: .It Xo Ic get
                    110: .Op Ar flags
                    111: .Ar remote-path
                    112: .Op Ar local-path
                    113: .Xc
1.1       djm       114: Retrieve the
1.5       stevesk   115: .Ar remote-path
1.1       djm       116: and store it on the local machine.
                    117: If the local
1.5       stevesk   118: path name is not specified, it is given the same name it has on the
1.7       djm       119: remote machine. If the
                    120: .Fl P
                    121: flag is specified, then the file's full permission and access time are
                    122: copied too.
1.3       deraadt   123: .It Ic lls Op Ar ls-options Op Ar path
1.1       djm       124: Display local directory listing of either
                    125: .Ar path
                    126: or current directory if
                    127: .Ar path
1.5       stevesk   128: is not specified.
1.3       deraadt   129: .It Ic lmkdir Ar path
1.1       djm       130: Create local directory specified by
1.3       deraadt   131: .Ar path .
                    132: .It Ic lpwd
                    133: Print local working directory.
                    134: .It Ic ls Op Ar path
1.1       djm       135: Display remote directory listing of either
                    136: .Ar path
1.5       stevesk   137: or current directory if
                    138: .Ar path
                    139: is not specified.
1.3       deraadt   140: .It Ic lumask Ar umask
1.1       djm       141: Set local umask to
1.3       deraadt   142: .Ar umask .
                    143: .It Ic mkdir Ar path
1.1       djm       144: Create remote directory specified by
1.3       deraadt   145: .Ar path .
1.7       djm       146: .It Xo Ic put
                    147: .Op Ar flags
                    148: .Ar local-path
                    149: .Op Ar local-path
                    150: .Xc
1.1       djm       151: Upload
1.5       stevesk   152: .Ar local-path
                    153: and store it on the remote machine. If the remote path name is not specified,
1.7       djm       154: it is given the same name it has on the local machine. If the
                    155: .Fl P
                    156: flag is specified, then the file's full permission and access time are
                    157: copied too.
1.3       deraadt   158: .It Ic pwd
                    159: Display remote working directory.
                    160: .It Ic exit
                    161: Quit sftp.
                    162: .It Ic quit
                    163: Quit sftp.
                    164: .It Ic rename Ar oldpath Ar newpath
1.1       djm       165: Rename remote file from
                    166: .Ar oldpath
                    167: to
1.3       deraadt   168: .Ar newpath .
                    169: .It Ic rmdir Ar path
1.1       djm       170: Remove remote directory specified by
1.3       deraadt   171: .Ar path .
                    172: .It Ic rm Ar path
1.1       djm       173: Delete remote file specified by
1.3       deraadt   174: .Ar path .
1.1       djm       175: .It Ic ! Ar command
                    176: Execute
                    177: .Ar command
1.3       deraadt   178: in local shell.
1.1       djm       179: .It Ic !
1.3       deraadt   180: Escape to local shell.
                    181: .It Ic ?
1.5       stevesk   182: Synonym for help.
1.4       itojun    183: .El
1.1       djm       184: .Sh AUTHORS
                    185: Damien Miller <djm@mindrot.org>
                    186: .Sh SEE ALSO
                    187: .Xr ssh 1 ,
                    188: .Xr ssh-add 1 ,
                    189: .Xr ssh-keygen 1 ,
1.3       deraadt   190: .Xr sshd 8 ,
                    191: .Xr scp 1
                    192: