anchor . in the path check for root
authorKeith Bostic <bostic@ucbvax.Berkeley.EDU>
Tue, 14 Apr 1992 09:51:34 +0000 (01:51 -0800)
committerKeith Bostic <bostic@ucbvax.Berkeley.EDU>
Tue, 14 Apr 1992 09:51:34 +0000 (01:51 -0800)
SCCS-vsn: etc/security 5.20

usr/src/etc/security

index 52181e4..f8da0d9 100644 (file)
@@ -1,6 +1,6 @@
 #!/bin/sh -
 #
 #!/bin/sh -
 #
-#      @(#)security    5.19 (Berkeley) %G%
+#      @(#)security    5.20 (Berkeley) %G%
 #
 
 # Script to check basic system security.  Checks included are:
 #
 
 # Script to check basic system security.  Checks included are:
@@ -123,7 +123,7 @@ for i in $list ; do
                        /bin/ls -ldgT \$path > $TMP1
 end-of-csh
                awk '{
                        /bin/ls -ldgT \$path > $TMP1
 end-of-csh
                awk '{
-                       if ($10 ~ /\./) {
+                       if ($10 ~ /^\./$) {
                                print "The root path includes .";
                                next;
                        }
                                print "The root path includes .";
                                next;
                        }
@@ -166,7 +166,7 @@ for i in $list; do
                        /bin/ls -ldgT \$list > $TMP1
 end-of-sh
                awk '{
                        /bin/ls -ldgT \$list > $TMP1
 end-of-sh
                awk '{
-                       if ($10 ~ /\./) {
+                       if ($10 ~ /^\./$) {
                                print "The root path includes .";
                                next;
                        }
                                print "The root path includes .";
                                next;
                        }