[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.123

1.123   ! djm         1: .\" $OpenBSD: sftp.1,v 1.122 2018/11/16 02:30:20 djm 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: .\"
1.123   ! djm        25: .Dd $Mdocdate: November 16 2018 $
1.1       djm        26: .Dt SFTP 1
                     27: .Os
                     28: .Sh NAME
                     29: .Nm sftp
1.44      jmc        30: .Nd secure file transfer program
1.1       djm        31: .Sh SYNOPSIS
1.43      jmc        32: .Nm sftp
1.106     djm        33: .Op Fl 46aCfpqrv
1.46      jmc        34: .Op Fl B Ar buffer_size
1.29      markus     35: .Op Fl b Ar batchfile
1.70      djm        36: .Op Fl c Ar cipher
1.72      djm        37: .Op Fl D Ar sftp_server_path
1.46      jmc        38: .Op Fl F Ar ssh_config
1.73      jmc        39: .Op Fl i Ar identity_file
1.85      djm        40: .Op Fl l Ar limit
1.29      markus     41: .Op Fl o Ar ssh_option
1.72      djm        42: .Op Fl P Ar port
1.30      djm        43: .Op Fl R Ar num_requests
1.26      stevesk    44: .Op Fl S Ar program
1.46      jmc        45: .Op Fl s Ar subsystem | sftp_server
1.111     millert    46: .Ar destination
1.1       djm        47: .Sh DESCRIPTION
                     48: .Nm
1.111     millert    49: is a file transfer program, similar to
1.1       djm        50: .Xr ftp 1 ,
                     51: which performs all operations over an encrypted
                     52: .Xr ssh 1
                     53: transport.
                     54: It may also use many features of ssh, such as public key authentication and
                     55: compression.
1.111     millert    56: .Pp
                     57: The
                     58: .Ar destination
                     59: may be specified either as
1.112     jmc        60: .Sm off
                     61: .Oo user @ Oc host Op : path
                     62: .Sm on
                     63: or as a URI in the form
                     64: .Sm off
                     65: .No sftp:// Oo user @ Oc host Oo : port Oc Op / path .
                     66: .Sm on
1.111     millert    67: .Pp
                     68: If the
                     69: .Ar destination
                     70: includes a
                     71: .Ar path
                     72: and it is not a directory,
1.1       djm        73: .Nm
1.111     millert    74: will retrieve files automatically if a non-interactive
1.18      stevesk    75: authentication method is used; otherwise it will do so after
                     76: successful interactive authentication.
1.15      mouring    77: .Pp
1.111     millert    78: If no
                     79: .Ar path
                     80: is specified, or if the
                     81: .Ar path
                     82: is a directory,
1.60      jaredy     83: .Nm
1.111     millert    84: will log in to the specified
                     85: .Ar host
                     86: and enter interactive command mode, changing to the remote directory
                     87: if one was specified.
                     88: An optional trailing slash can be used to force the
                     89: .Ar path
                     90: to be interpreted as a directory.
1.1       djm        91: .Pp
1.111     millert    92: Since the destination formats use colon characters to delimit host
                     93: names from path names or port numbers, IPv6 addresses must be
                     94: enclosed in square brackets to avoid ambiguity.
1.89      djm        95: .Pp
1.1       djm        96: The options are as follows:
                     97: .Bl -tag -width Ds
1.70      djm        98: .It Fl 4
                     99: Forces
                    100: .Nm
                    101: to use IPv4 addresses only.
                    102: .It Fl 6
                    103: Forces
                    104: .Nm
                    105: to use IPv6 addresses only.
1.94      jmc       106: .It Fl a
1.99      jmc       107: Attempt to continue interrupted transfers rather than overwriting
1.98      logan     108: existing partial or complete copies of files.
1.99      jmc       109: If the partial contents differ from those being transferred,
1.98      logan     110: then the resultant file is likely to be corrupt.
1.46      jmc       111: .It Fl B Ar buffer_size
                    112: Specify the size of the buffer that
                    113: .Nm
                    114: uses when transferring files.
                    115: Larger buffers require fewer round trips at the cost of higher
                    116: memory consumption.
                    117: The default is 32768 bytes.
1.10      deraadt   118: .It Fl b Ar batchfile
                    119: Batch mode reads a series of commands from an input
1.13      stevesk   120: .Ar batchfile
1.10      deraadt   121: instead of
1.13      stevesk   122: .Em stdin .
                    123: Since it lacks user interaction it should be used in conjunction with
1.111     millert   124: non-interactive authentication to obviate the need to enter a password
                    125: at connection time (see
                    126: .Xr sshd 8
                    127: and
                    128: .Xr ssh-keygen 1
                    129: for details).
1.122     djm       130: .Pp
1.50      djm       131: A
1.51      jmc       132: .Ar batchfile
                    133: of
                    134: .Sq \-
1.50      djm       135: may be used to indicate standard input.
1.13      stevesk   136: .Nm
1.21      itojun    137: will abort if any of the following
                    138: commands fail:
1.121     schwarze  139: .Ic get , put , reget , reput , rename , ln ,
1.41      jmc       140: .Ic rm , mkdir , chdir , ls ,
1.66      jmc       141: .Ic lchdir , chmod , chown ,
1.88      djm       142: .Ic chgrp , lpwd , df , symlink ,
1.10      deraadt   143: and
1.13      stevesk   144: .Ic lmkdir .
1.122     djm       145: .Pp
1.41      jmc       146: Termination on error can be suppressed on a command by command basis by
                    147: prefixing the command with a
1.51      jmc       148: .Sq \-
1.44      jmc       149: character (for example,
                    150: .Ic -rm /tmp/blah* ) .
1.122     djm       151: Echo of the command may be suppressed by prefixing the command with a
                    152: .Sq @
                    153: character.
                    154: These two prefixes may be combined in any order, for example
                    155: .Ic -@ls /bsd .
1.71      jmc       156: .It Fl C
                    157: Enables compression (via ssh's
                    158: .Fl C
                    159: flag).
1.70      djm       160: .It Fl c Ar cipher
                    161: Selects the cipher to use for encrypting the data transfers.
                    162: This option is directly passed to
                    163: .Xr ssh 1 .
1.72      djm       164: .It Fl D Ar sftp_server_path
                    165: Connect directly to a local sftp server
                    166: (rather than via
                    167: .Xr ssh 1 ) .
                    168: This option may be useful in debugging the client and server.
1.46      jmc       169: .It Fl F Ar ssh_config
                    170: Specifies an alternative
                    171: per-user configuration file for
                    172: .Xr ssh 1 .
                    173: This option is directly passed to
                    174: .Xr ssh 1 .
1.95      djm       175: .It Fl f
                    176: Requests that files be flushed to disk immediately after transfer.
                    177: When uploading files, this feature is only enabled if the server
                    178: implements the "fsync@openssh.com" extension.
1.70      djm       179: .It Fl i Ar identity_file
                    180: Selects the file from which the identity (private key) for public key
                    181: authentication is read.
                    182: This option is directly passed to
                    183: .Xr ssh 1 .
1.85      djm       184: .It Fl l Ar limit
                    185: Limits the used bandwidth, specified in Kbit/s.
1.1       djm       186: .It Fl o Ar ssh_option
1.23      stevesk   187: Can be used to pass options to
                    188: .Nm ssh
1.35      stevesk   189: in the format used in
                    190: .Xr ssh_config 5 .
                    191: This is useful for specifying options
1.23      stevesk   192: for which there is no separate
                    193: .Nm sftp
1.44      jmc       194: command-line flag.
                    195: For example, to specify an alternate port use:
1.26      stevesk   196: .Ic sftp -oPort=24 .
1.46      jmc       197: For full details of the options listed below, and their possible values, see
                    198: .Xr ssh_config 5 .
                    199: .Pp
                    200: .Bl -tag -width Ds -offset indent -compact
                    201: .It AddressFamily
                    202: .It BatchMode
                    203: .It BindAddress
1.114     jmc       204: .It BindInterface
1.97      djm       205: .It CanonicalDomains
                    206: .It CanonicalizeFallbackLocal
                    207: .It CanonicalizeHostname
                    208: .It CanonicalizeMaxDots
                    209: .It CanonicalizePermittedCNAMEs
1.120     jmc       210: .It CASignatureAlgorithms
1.102     jmc       211: .It CertificateFile
1.46      jmc       212: .It ChallengeResponseAuthentication
                    213: .It CheckHostIP
                    214: .It Ciphers
                    215: .It Compression
1.110     naddy     216: .It ConnectionAttempts
1.54      dtucker   217: .It ConnectTimeout
1.55      djm       218: .It ControlMaster
                    219: .It ControlPath
1.91      djm       220: .It ControlPersist
1.46      jmc       221: .It GlobalKnownHostsFile
                    222: .It GSSAPIAuthentication
                    223: .It GSSAPIDelegateCredentials
1.61      jmc       224: .It HashKnownHosts
1.46      jmc       225: .It Host
                    226: .It HostbasedAuthentication
1.101     djm       227: .It HostbasedKeyTypes
1.46      jmc       228: .It HostKeyAlgorithms
                    229: .It HostKeyAlias
                    230: .It HostName
1.104     jmc       231: .It IdentitiesOnly
1.103     markus    232: .It IdentityAgent
1.46      jmc       233: .It IdentityFile
1.87      jmc       234: .It IPQoS
1.91      djm       235: .It KbdInteractiveAuthentication
1.58      djm       236: .It KbdInteractiveDevices
1.86      jmc       237: .It KexAlgorithms
1.46      jmc       238: .It LogLevel
                    239: .It MACs
                    240: .It NoHostAuthenticationForLocalhost
                    241: .It NumberOfPasswordPrompts
                    242: .It PasswordAuthentication
1.83      markus    243: .It PKCS11Provider
1.46      jmc       244: .It Port
                    245: .It PreferredAuthentications
                    246: .It ProxyCommand
1.105     jmc       247: .It ProxyJump
1.108     jmc       248: .It PubkeyAcceptedKeyTypes
1.46      jmc       249: .It PubkeyAuthentication
1.63      dtucker   250: .It RekeyLimit
1.53      jmc       251: .It SendEnv
1.49      markus    252: .It ServerAliveInterval
                    253: .It ServerAliveCountMax
1.116     jmc       254: .It SetEnv
1.46      jmc       255: .It StrictHostKeyChecking
1.48      markus    256: .It TCPKeepAlive
1.100     djm       257: .It UpdateHostKeys
1.46      jmc       258: .It User
                    259: .It UserKnownHostsFile
                    260: .It VerifyHostKeyDNS
                    261: .El
1.72      djm       262: .It Fl P Ar port
                    263: Specifies the port to connect to on the remote host.
1.74      djm       264: .It Fl p
                    265: Preserves modification times, access times, and modes from the
                    266: original files transferred.
1.70      djm       267: .It Fl q
                    268: Quiet mode: disables the progress meter as well as warning and
                    269: diagnostic messages from
                    270: .Xr ssh 1 .
1.30      djm       271: .It Fl R Ar num_requests
1.44      jmc       272: Specify how many requests may be outstanding at any one time.
                    273: Increasing this may slightly improve file transfer speed
                    274: but will increase memory usage.
1.67      djm       275: The default is 64 outstanding requests.
1.74      djm       276: .It Fl r
                    277: Recursively copy entire directories when uploading and downloading.
                    278: Note that
                    279: .Nm
                    280: does not follow symbolic links encountered in the tree traversal.
1.26      stevesk   281: .It Fl S Ar program
                    282: Name of the
                    283: .Ar program
                    284: to use for the encrypted connection.
                    285: The program must understand
                    286: .Xr ssh 1
                    287: options.
1.46      jmc       288: .It Fl s Ar subsystem | sftp_server
                    289: Specifies the SSH2 subsystem or the path for an sftp server
                    290: on the remote host.
1.109     jmc       291: A path is useful when the remote
1.46      jmc       292: .Xr sshd 8
                    293: does not have an sftp subsystem configured.
                    294: .It Fl v
                    295: Raise logging level.
                    296: This option is also passed to ssh.
1.1       djm       297: .El
                    298: .Sh INTERACTIVE COMMANDS
1.2       djm       299: Once in interactive mode,
                    300: .Nm
1.21      itojun    301: understands a set of commands similar to those of
1.1       djm       302: .Xr ftp 1 .
1.60      jaredy    303: Commands are case insensitive.
                    304: Pathnames that contain spaces must be enclosed in quotes.
                    305: Any special characters contained within pathnames that are recognized by
                    306: .Xr glob 3
                    307: must be escaped with backslashes
                    308: .Pq Sq \e .
                    309: .Bl -tag -width Ds
1.22      markus    310: .It Ic bye
1.44      jmc       311: Quit
                    312: .Nm sftp .
1.113     djm       313: .It Ic cd Op Ar path
1.21      itojun    314: Change remote directory to
1.3       deraadt   315: .Ar path .
1.113     djm       316: If
                    317: .Ar path
                    318: is not specified, then change directory to the one the session started in.
1.123   ! djm       319: .It Xo Ic chgrp
        !           320: .Op Fl h
        !           321: .Ar grp
        !           322: .Ar path
        !           323: .Xc
1.21      itojun    324: Change group of file
1.5       stevesk   325: .Ar path
                    326: to
1.1       djm       327: .Ar grp .
1.123   ! djm       328: If the
        !           329: .Fl h
        !           330: flag is specified, then symlinks will not be followed.
1.60      jaredy    331: .Ar path
                    332: may contain
1.118     kn        333: .Xr glob 7
1.60      jaredy    334: characters and may match multiple files.
1.1       djm       335: .Ar grp
1.5       stevesk   336: must be a numeric GID.
1.123   ! djm       337: .It Xo Ic chmod
        !           338: .Op Fl h
        !           339: .Ar mode
        !           340: .Ar path
        !           341: .Xc
1.21      itojun    342: Change permissions of file
1.5       stevesk   343: .Ar path
                    344: to
1.3       deraadt   345: .Ar mode .
1.123   ! djm       346: If the
        !           347: .Fl h
        !           348: flag is specified, then symlinks will not be followed.
1.60      jaredy    349: .Ar path
                    350: may contain
1.118     kn        351: .Xr glob 7
1.60      jaredy    352: characters and may match multiple files.
1.123   ! djm       353: .It Xo Ic chown
        !           354: .Op Fl h
        !           355: .Ar own
        !           356: .Ar path
        !           357: .Xc
1.21      itojun    358: Change owner of file
1.5       stevesk   359: .Ar path
                    360: to
1.1       djm       361: .Ar own .
1.123   ! djm       362: If the
        !           363: .Fl h
        !           364: flag is specified, then symlinks will not be followed.
1.60      jaredy    365: .Ar path
                    366: may contain
1.118     kn        367: .Xr glob 7
1.60      jaredy    368: characters and may match multiple files.
1.1       djm       369: .Ar own
                    370: must be a numeric UID.
1.65      djm       371: .It Xo Ic df
                    372: .Op Fl hi
                    373: .Op Ar path
                    374: .Xc
                    375: Display usage information for the filesystem holding the current directory
                    376: (or
                    377: .Ar path
                    378: if specified).
                    379: If the
                    380: .Fl h
                    381: flag is specified, the capacity information will be displayed using
                    382: "human-readable" suffixes.
                    383: The
                    384: .Fl i
                    385: flag requests display of inode information in addition to capacity information.
                    386: This command is only supported on servers that implement the
                    387: .Dq statvfs@openssh.com
                    388: extension.
1.11      deraadt   389: .It Ic exit
1.44      jmc       390: Quit
                    391: .Nm sftp .
1.7       djm       392: .It Xo Ic get
1.95      djm       393: .Op Fl afPpr
1.7       djm       394: .Ar remote-path
                    395: .Op Ar local-path
                    396: .Xc
1.1       djm       397: Retrieve the
1.5       stevesk   398: .Ar remote-path
1.1       djm       399: and store it on the local machine.
                    400: If the local
1.21      itojun    401: path name is not specified, it is given the same name it has on the
1.44      jmc       402: remote machine.
1.60      jaredy    403: .Ar remote-path
                    404: may contain
1.118     kn        405: .Xr glob 7
1.60      jaredy    406: characters and may match multiple files.
                    407: If it does and
                    408: .Ar local-path
                    409: is specified, then
                    410: .Ar local-path
                    411: must specify a directory.
1.74      djm       412: .Pp
1.92      djm       413: If the
                    414: .Fl a
                    415: flag is specified, then attempt to resume partial transfers of existing files.
                    416: Note that resumption assumes that any partial copy of the local file matches
                    417: the remote copy.
1.93      djm       418: If the remote file contents differ from the partial local copy then the
                    419: resultant file is likely to be corrupt.
1.92      djm       420: .Pp
1.95      djm       421: If the
                    422: .Fl f
                    423: flag is specified, then
                    424: .Xr fsync 2
1.96      jmc       425: will be called after the file transfer has completed to flush the file
1.95      djm       426: to disk.
                    427: .Pp
1.76      jmc       428: If either the
1.75      djm       429: .Fl P
1.74      djm       430: or
                    431: .Fl p
1.60      jaredy    432: flag is specified, then full file permissions and access times are
1.7       djm       433: copied too.
1.74      djm       434: .Pp
                    435: If the
                    436: .Fl r
                    437: flag is specified then directories will be copied recursively.
                    438: Note that
                    439: .Nm
                    440: does not follow symbolic links when performing recursive transfers.
1.11      deraadt   441: .It Ic help
                    442: Display help text.
1.113     djm       443: .It Ic lcd Op Ar path
1.46      jmc       444: Change local directory to
                    445: .Ar path .
1.113     djm       446: If
                    447: .Ar path
                    448: is not specified, then change directory to the local user's home directory.
1.3       deraadt   449: .It Ic lls Op Ar ls-options Op Ar path
1.21      itojun    450: Display local directory listing of either
1.1       djm       451: .Ar path
                    452: or current directory if
                    453: .Ar path
1.5       stevesk   454: is not specified.
1.60      jaredy    455: .Ar ls-options
                    456: may contain any flags supported by the local system's
                    457: .Xr ls 1
                    458: command.
                    459: .Ar path
                    460: may contain
1.118     kn        461: .Xr glob 7
1.60      jaredy    462: characters and may match multiple files.
1.3       deraadt   463: .It Ic lmkdir Ar path
1.1       djm       464: Create local directory specified by
1.3       deraadt   465: .Ar path .
1.88      djm       466: .It Xo Ic ln
                    467: .Op Fl s
                    468: .Ar oldpath
                    469: .Ar newpath
                    470: .Xc
                    471: Create a link from
1.12      djm       472: .Ar oldpath
                    473: to
                    474: .Ar newpath .
1.88      djm       475: If the
                    476: .Fl s
                    477: flag is specified the created link is a symbolic link, otherwise it is
                    478: a hard link.
1.3       deraadt   479: .It Ic lpwd
                    480: Print local working directory.
1.36      djm       481: .It Xo Ic ls
1.82      jmc       482: .Op Fl 1afhlnrSt
1.36      djm       483: .Op Ar path
                    484: .Xc
1.60      jaredy    485: Display a remote directory listing of either
1.1       djm       486: .Ar path
1.60      jaredy    487: or the current directory if
1.5       stevesk   488: .Ar path
1.44      jmc       489: is not specified.
1.60      jaredy    490: .Ar path
                    491: may contain
1.118     kn        492: .Xr glob 7
1.60      jaredy    493: characters and may match multiple files.
                    494: .Pp
                    495: The following flags are recognized and alter the behaviour of
                    496: .Ic ls
                    497: accordingly:
                    498: .Bl -tag -width Ds
                    499: .It Fl 1
                    500: Produce single columnar output.
                    501: .It Fl a
                    502: List files beginning with a dot
                    503: .Pq Sq \&. .
                    504: .It Fl f
                    505: Do not sort the listing.
                    506: The default sort order is lexicographical.
1.81      djm       507: .It Fl h
                    508: When used with a long format option, use unit suffixes: Byte, Kilobyte,
                    509: Megabyte, Gigabyte, Terabyte, Petabyte, and Exabyte in order to reduce
                    510: the number of digits to four or fewer using powers of 2 for sizes (K=1024,
                    511: M=1048576, etc.).
1.82      jmc       512: .It Fl l
                    513: Display additional details including permissions
                    514: and ownership information.
1.60      jaredy    515: .It Fl n
                    516: Produce a long listing with user and group information presented
1.56      djm       517: numerically.
1.60      jaredy    518: .It Fl r
                    519: Reverse the sort order of the listing.
                    520: .It Fl S
                    521: Sort the listing by file size.
                    522: .It Fl t
                    523: Sort the listing by last modification time.
                    524: .El
1.3       deraadt   525: .It Ic lumask Ar umask
1.21      itojun    526: Set local umask to
1.3       deraadt   527: .Ar umask .
                    528: .It Ic mkdir Ar path
1.1       djm       529: Create remote directory specified by
1.3       deraadt   530: .Ar path .
1.40      fgsch     531: .It Ic progress
                    532: Toggle display of progress meter.
1.7       djm       533: .It Xo Ic put
1.98      logan     534: .Op Fl afPpr
1.7       djm       535: .Ar local-path
1.37      djm       536: .Op Ar remote-path
1.7       djm       537: .Xc
1.1       djm       538: Upload
1.5       stevesk   539: .Ar local-path
1.44      jmc       540: and store it on the remote machine.
                    541: If the remote path name is not specified, it is given the same name it has
                    542: on the local machine.
1.60      jaredy    543: .Ar local-path
                    544: may contain
1.118     kn        545: .Xr glob 7
1.60      jaredy    546: characters and may match multiple files.
                    547: If it does and
                    548: .Ar remote-path
                    549: is specified, then
                    550: .Ar remote-path
                    551: must specify a directory.
1.95      djm       552: .Pp
                    553: If the
1.99      jmc       554: .Fl a
1.98      logan     555: flag is specified, then attempt to resume partial
                    556: transfers of existing files.
1.99      jmc       557: Note that resumption assumes that any partial copy of the remote file
1.98      logan     558: matches the local copy.
                    559: If the local file contents differ from the remote local copy then
                    560: the resultant file is likely to be corrupt.
                    561: .Pp
                    562: If the
1.95      djm       563: .Fl f
                    564: flag is specified, then a request will be sent to the server to call
                    565: .Xr fsync 2
                    566: after the file has been transferred.
                    567: Note that this is only supported by servers that implement
                    568: the "fsync@openssh.com" extension.
1.74      djm       569: .Pp
1.90      dtucker   570: If either the
1.7       djm       571: .Fl P
1.74      djm       572: or
                    573: .Fl p
                    574: flag is specified, then full file permissions and access times are
1.7       djm       575: copied too.
1.74      djm       576: .Pp
                    577: If the
                    578: .Fl r
                    579: flag is specified then directories will be copied recursively.
                    580: Note that
                    581: .Nm
                    582: does not follow symbolic links when performing recursive transfers.
1.3       deraadt   583: .It Ic pwd
                    584: Display remote working directory.
                    585: .It Ic quit
1.44      jmc       586: Quit
                    587: .Nm sftp .
1.92      djm       588: .It Xo Ic reget
                    589: .Op Fl Ppr
                    590: .Ar remote-path
                    591: .Op Ar local-path
                    592: .Xc
                    593: Resume download of
                    594: .Ar remote-path .
                    595: Equivalent to
                    596: .Ic get
                    597: with the
1.98      logan     598: .Fl a
                    599: flag set.
                    600: .It Xo Ic reput
                    601: .Op Fl Ppr
                    602: .Op Ar local-path
                    603: .Ar remote-path
                    604: .Xc
                    605: Resume upload of
                    606: .Op Ar local-path .
                    607: Equivalent to
                    608: .Ic put
1.99      jmc       609: with the
1.92      djm       610: .Fl a
                    611: flag set.
1.3       deraadt   612: .It Ic rename Ar oldpath Ar newpath
1.1       djm       613: Rename remote file from
                    614: .Ar oldpath
                    615: to
1.3       deraadt   616: .Ar newpath .
1.46      jmc       617: .It Ic rm Ar path
                    618: Delete remote file specified by
                    619: .Ar path .
1.3       deraadt   620: .It Ic rmdir Ar path
1.1       djm       621: Remove remote directory specified by
1.3       deraadt   622: .Ar path .
1.12      djm       623: .It Ic symlink Ar oldpath Ar newpath
1.21      itojun    624: Create a symbolic link from
1.12      djm       625: .Ar oldpath
                    626: to
                    627: .Ar newpath .
1.38      fgsch     628: .It Ic version
                    629: Display the
                    630: .Nm
                    631: protocol version.
1.69      sobrado   632: .It Ic \&! Ns Ar command
1.21      itojun    633: Execute
1.1       djm       634: .Ar command
1.3       deraadt   635: in local shell.
1.45      jmc       636: .It Ic \&!
1.3       deraadt   637: Escape to local shell.
1.45      jmc       638: .It Ic \&?
1.5       stevesk   639: Synonym for help.
1.4       itojun    640: .El
1.1       djm       641: .Sh SEE ALSO
1.46      jmc       642: .Xr ftp 1 ,
1.60      jaredy    643: .Xr ls 1 ,
1.17      markus    644: .Xr scp 1 ,
1.1       djm       645: .Xr ssh 1 ,
                    646: .Xr ssh-add 1 ,
                    647: .Xr ssh-keygen 1 ,
1.119     jmc       648: .Xr ssh_config 5 ,
1.118     kn        649: .Xr glob 7 ,
1.17      markus    650: .Xr sftp-server 8 ,
                    651: .Xr sshd 8
                    652: .Rs
1.20      deraadt   653: .%A T. Ylonen
                    654: .%A S. Lehtinen
1.17      markus    655: .%T "SSH File Transfer Protocol"
                    656: .%N draft-ietf-secsh-filexfer-00.txt
                    657: .%D January 2001
                    658: .%O work in progress material
                    659: .Re