summaryrefslogtreecommitdiff
path: root/sftp.1
diff options
context:
space:
mode:
authordjm@openbsd.org <djm@openbsd.org>2019-01-16 23:23:45 +0000
committerDamien Miller <djm@mindrot.org>2019-01-17 11:08:13 +1100
commit60d8c84e0887514c99c9ce071965fafaa1c3d34a (patch)
tree771daf5a0f48b41115daf2b9b552e4e6d10dba7d /sftp.1
parentdbbc7e0eab7262f34b8e0cd6efecd1c77b905ed0 (diff)
upstream: Add "-h" flag to sftp chown/chgrp/chmod commands to
request they do not follow symlinks. Requires recently-committed lsetstat@openssh.com extension on the server side. ok markus@ dtucker@ OpenBSD-Commit-ID: f93bb3f6f7eb2fb7ef1e59126e72714f1626d604
Diffstat (limited to 'sftp.1')
-rw-r--r--sftp.131
1 files changed, 26 insertions, 5 deletions
diff --git a/sftp.1 b/sftp.1
index 7140bc19..722a3441 100644
--- a/sftp.1
+++ b/sftp.1
@@ -1,4 +1,4 @@
-.\" $OpenBSD: sftp.1,v 1.122 2018/11/16 02:30:20 djm Exp $
+.\" $OpenBSD: sftp.1,v 1.123 2019/01/16 23:23:45 djm Exp $
.\"
.\" Copyright (c) 2001 Damien Miller. All rights reserved.
.\"
@@ -22,7 +22,7 @@
.\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
.\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
.\"
-.Dd $Mdocdate: November 16 2018 $
+.Dd $Mdocdate: January 16 2019 $
.Dt SFTP 1
.Os
.Sh NAME
@@ -316,31 +316,52 @@ Change remote directory to
If
.Ar path
is not specified, then change directory to the one the session started in.
-.It Ic chgrp Ar grp Ar path
+.It Xo Ic chgrp
+.Op Fl h
+.Ar grp
+.Ar path
+.Xc
Change group of file
.Ar path
to
.Ar grp .
+If the
+.Fl h
+flag is specified, then symlinks will not be followed.
.Ar path
may contain
.Xr glob 7
characters and may match multiple files.
.Ar grp
must be a numeric GID.
-.It Ic chmod Ar mode Ar path
+.It Xo Ic chmod
+.Op Fl h
+.Ar mode
+.Ar path
+.Xc
Change permissions of file
.Ar path
to
.Ar mode .
+If the
+.Fl h
+flag is specified, then symlinks will not be followed.
.Ar path
may contain
.Xr glob 7
characters and may match multiple files.
-.It Ic chown Ar own Ar path
+.It Xo Ic chown
+.Op Fl h
+.Ar own
+.Ar path
+.Xc
Change owner of file
.Ar path
to
.Ar own .
+If the
+.Fl h
+flag is specified, then symlinks will not be followed.
.Ar path
may contain
.Xr glob 7