summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>1997-09-02 06:46:43 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>1997-09-02 06:46:43 +0000
commit752d3ad5deae9e43f90ae1bd89ac2981d468ceeb (patch)
tree50cddf5c62eb101a30f0ec12f03094980d8d3c32
parent0726b1698d830803298b771b5ecb19d8b0469022 (diff)
better path handling; jbernard@tater.mines.edu, netbsd pr#3995
-rw-r--r--etc/security10
1 files changed, 7 insertions, 3 deletions
diff --git a/etc/security b/etc/security
index e06aa69f23c..0f7060200ec 100644
--- a/etc/security
+++ b/etc/security
@@ -1,6 +1,6 @@
#!/bin/sh -
#
-# $OpenBSD: security,v 1.20 1997/06/23 02:54:31 millert Exp $
+# $OpenBSD: security,v 1.21 1997/09/02 06:46:42 deraadt Exp $
# from: @(#)security 8.1 (Berkeley) 6/9/93
#
@@ -141,11 +141,13 @@ for i in $list ; do
{ print "Root umask is group writeable" }
$2 % 10 < 2 \
{ print "Root umask is other writeable" }' >> $OUTPUT
+ SAVE_PATH=$PATH
+ unset PATH
/bin/csh -f -s << end-of-csh > /dev/null 2>&1
- unset path
source $i
/bin/ls -ldgT \$path > $TMP1
end-of-csh
+ PATH=$SAVE_PATH
awk '{
if ($10 ~ /^\.$/) {
print "The root path includes .";
@@ -183,12 +185,14 @@ for i in $list; do
{ print "Root umask is group writeable" } \
$2 % 10 < 2 \
{ print "Root umask is other writeable" }' >> $OUTPUT
+ SAVE_PATH=$PATH
+ unset PATH
/bin/sh << end-of-sh > /dev/null 2>&1
- PATH=
. $i
list=\`echo \$PATH | /usr/bin/sed -e 's/:/ /g'\`
/bin/ls -ldgT \$list > $TMP1
end-of-sh
+ PATH=$SAVE_PATH
awk '{
if ($10 ~ /^\.$/) {
print "The root path includes .";