aboutsummaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorGiorgos Keramidas <keramida@FreeBSD.org>2002-06-24 22:06:47 +0000
committerGiorgos Keramidas <keramida@FreeBSD.org>2002-06-24 22:06:47 +0000
commit09152a86ff4390fe1bd36118cf52db68f6f99d75 (patch)
tree8402afb342e6cdd1cf3c65ef0009bef2ff570dcf /bin
parente255b776bcc2db5d4643aa998867543dbd71cd0b (diff)
downloadsrc-09152a86ff4390fe1bd36118cf52db68f6f99d75.tar.gz
src-09152a86ff4390fe1bd36118cf52db68f6f99d75.zip
Add a description of the restrictions that red(1) imposes to users,
and a warning that this "restricted mode" can be bypassed easily by using symlinks, so that users don't depend too much on it. PR: docs/35940 Submitted by: Gary W. Swearingen <swear@blarg.net> Reviewed by: jmallett MFC after: 1 week
Notes
Notes: svn path=/head/; revision=98780
Diffstat (limited to 'bin')
-rw-r--r--bin/ed/ed.131
1 files changed, 24 insertions, 7 deletions
diff --git a/bin/ed/ed.1 b/bin/ed/ed.1
index 51759242cbfc..8509c6edc7d7 100644
--- a/bin/ed/ed.1
+++ b/bin/ed/ed.1
@@ -12,19 +12,36 @@
.Op Fl sx
.Op Fl p Ar string
.Op Ar file
-.\" .LP
-.\" red [-] [-sx] [-p \fIstring\fR] [\fIfile\fR]
+.LP
+.Nm red
+.Op Fl
+.Op Fl sx
+.Op Fl p Ar string
+.Op Ar file
.Sh DESCRIPTION
The
.Nm
utility is a line-oriented text editor.
It is used to create, display, modify and otherwise manipulate text
files.
-.\" .B red
-.\" is a restricted
-.\" .BR ed :
-.\" it can only edit files in the current
-.\" directory and cannot execute shell commands.
+When invoked as
+.Nm red ,
+the editor runs in
+.Qq restricted
+mode, in which the only difference is that the editor restricts the
+use of filenames which start with
+.Ql \&!
+(interpreted as shell commands by
+.Nm ed )
+or contain a
+.Ql \&/ .
+Note that editing outside of the current directory is only prohibited
+if the user does not have write access to the current directory.
+If a user has write access to the current directory, then symbolic
+links can be created in the current directory, in which case
+.Nm red
+will not stop the user from editing the file that the symbolic link
+points to.
.Pp
If invoked with a
.Ar file