Merge of xfs-cmds-2.4.18:slinx:112264a by nathans.
authorTim Shimmin <tes@sgi.com>
Mon, 25 Feb 2002 22:39:00 +0000 (22:39 +0000)
committerTim Shimmin <tes@sgi.com>
Mon, 25 Feb 2002 22:39:00 +0000 (22:39 +0000)
  And some msgs.

051
051.out

diff --git a/051 b/051
index aae6458b5d11c0b05521b8058b09f19648a5fa17..01dd6c1db0677a7fa7045e2ee0c03281e307408a 100755 (executable)
--- a/051
+++ b/051
@@ -128,8 +128,10 @@ _acl_ls file1
 
 echo ""
 echo "--- Test get and set of ACL ---"
+echo "Note: Old interface gave an empty ACL - now output an ACL"
 chacl -l file1 | _acl_filter_id
-echo "Expect to FAIL" 
+echo "Try using single colon separator"
+echo "Note: Old interface FAILed because of single colon - new one allows it" 
 chacl u::r--,g::rwx,o:rw- file1 2>&1
 echo "Expect to PASS" 
 chacl u::r--,g::rwx,o::rw- file1 2>&1
@@ -293,6 +295,7 @@ echo "Remove ACLs..."
 chacl -R file1
 chacl -B acldir
 chacl -R acldir/file2
+echo "Note: Old interface would mean empty ACLs - now we show mode ACLs" 
 chacl -l file1 | _acl_filter_id
 chacl -l acldir | _acl_filter_id
 chacl -l acldir/file2 | _acl_filter_id
@@ -315,10 +318,10 @@ done
 popd >/dev/null
 chown -R 12345.54321 root
 echo "Change #1..."
-$runas -u 12345 -g 54321 -- /bin/chacl -r u::rwx,g::-w-,o::--x root
+$runas -u 12345 -g 54321 -- /usr/bin/chacl -r u::rwx,g::-w-,o::--x root
 find root -print | xargs chacl -l
 echo "Change #2..."
-$runas -u 12345 -g 54321 -- /bin/chacl -r u::---,g::---,o::--- root
+$runas -u 12345 -g 54321 -- /usr/bin/chacl -r u::---,g::---,o::--- root
 find root -print | xargs chacl -l
 
 
@@ -326,6 +329,7 @@ find root -print | xargs chacl -l
 
 echo ""
 echo "=== Test out error messages for ACL text parsing  ==="
+echo "Note: Old interface gave more informative error msgs"
 
 touch file1
 set -x
diff --git a/051.out b/051.out
index 50a84df301df22801e107476ca890f2ef39af1dc..2b5220f76decea5bc0141e88add65abfce05a0ae 100644 (file)
--- a/051.out
+++ b/051.out
@@ -5,10 +5,10 @@ Setup file
 -rwxrw-r-- id1 id2 file1
 
 --- Test get and set of ACL ---
-file1 []
-Expect to FAIL
-chacl: "u::r--,g::rwx,o:rw-" is an invalid ACL specification.
-cannot find permission separator after char ":" (position 16)
+Note: Old interface gave an empty ACL - now output an ACL
+file1 [u::rwx,g::rw-,o::r--]
+Try using single colon separator
+Note: Old interface FAILed because of single colon - new one allows it
 Expect to PASS
 file1 [u::r--,g::rwx,o::rw-]
 
@@ -50,23 +50,21 @@ Test was executed
 
 --- Test adding a USER ACE ---
 Expect to FAIL as no MASK provided
-chacl: "u::---,g::---,o::---,u:id2:r-x" is an invalid ACL specification.
-mask required and no mask
+chacl: access ACL 'u::---,g::---,o::---,u:id2:r-x': Missing or wrong entry at entry 3
 Ensure that ACL has not been changed
 file1 [u::---,g::---,o::r-x]
 Expect to PASS - USER ACE matches user
-file1 [u::---,g::---,o::---,u:id2:r-x,m::rwx]
+file1 [u::---,u:id2:r-x,g::---,m::rwx,o::---]
 Test was executed
 Expect to FAIL - USER ACE does not match user
 ./file1: Permission denied
 
 --- Test adding a GROUP ACE ---
 Expect to FAIL as no MASK provided
-chacl: "u::---,g::---,o::---,g:id2:r-x" is an invalid ACL specification.
-mask required and no mask
+chacl: access ACL 'u::---,g::---,o::---,g:id2:r-x': Missing or wrong entry at entry 3
 Ensure that ACL has not been changed
-file1 [u::---,g::---,o::---,u:id2:r-x,m::rwx]
-file1 [u::---,g::---,o::---,g:id2:r-x,m::rwx]
+file1 [u::---,u:id2:r-x,g::---,m::rwx,o::---]
+file1 [u::---,g::---,g:id2:r-x,m::rwx,o::---]
 Expect to PASS - GROUP ACE matches group
 Test was executed
 Expect to PASS - GROUP ACE matches sup group
@@ -75,7 +73,7 @@ Expect to FAIL - GROUP ACE does not match group
 ./file1: Permission denied
 
 --- Test MASK ---
-file1 [u::---,g::---,o::---,g:id2:r-x,m::-w-]
+file1 [u::---,g::---,g:id2:r-x,m::-w-,o::---]
 Expect to FAIL as MASK prohibits execution
 ./file1: Permission denied
 Expect to FAIL as MASK prohibits execution
@@ -90,7 +88,7 @@ Expect to PASS as should match on user
 Test was executed
 
 === Test can read ACLs without access permissions ===
-file1 [o::---,g::---,u::---]
+file1 [u::---,g::---,o::---]
 
 === Test Default ACLs ===
 acldir [u::rwx,g::rwx,o::rwx/u::r-x,g::r--,o::---]
@@ -100,13 +98,14 @@ file2 [u::r--,g::r--,o::---]
 file3 [u::r--,g::r--,o::---]
 
 === Removing ACLs ===
-file1 [o::---,g::---,u::---]
+file1 [u::---,g::---,o::---]
 acldir [u::rwx,g::rwx,o::rwx/u::r-x,g::r--,o::---]
 acldir/file2 [u::r--,g::r--,o::---]
 Remove ACLs...
-file1 []
-acldir []
-acldir/file2 []
+Note: Old interface would mean empty ACLs - now we show mode ACLs
+file1 [u::---,g::---,o::---]
+acldir [u::rwx,g::rwx,o::rwx]
+acldir/file2 [u::r--,g::r--,o::---]
 
 === Recursive change ACL ===
 Change #1...
@@ -199,31 +198,23 @@ root/b/c0 [u::---,g::---,o::---]
 root/b/c0/0 [u::---,g::---,o::---]
 
 === Test out error messages for ACL text parsing  ===
+Note: Old interface gave more informative error msgs
 + chacl u file1
-chacl: "u" is an invalid ACL specification.
-could not find qualifier separator after tag "u"
+chacl: u - Invalid argument
 + chacl u: file1
-chacl: "u:" is an invalid ACL specification.
-cannot find permission separator after char ":" (position 2)
+chacl: u: - Invalid argument
 + chacl u:rumpledumpleunknownuser file1
-chacl: "u:rumpledumpleunknownuser" is an invalid ACL specification.
-cannot find permission separator after char ":" (position 2)
+chacl: u:rumpledumpleunknownuser - Invalid argument
 + chacl u:rumpledumpleunknownuser: file1
-chacl: "u:rumpledumpleunknownuser:" is an invalid ACL specification.
-cannot find user "rumpledumpleunknownuser"
+chacl: u:rumpledumpleunknownuser: - Invalid argument
 + chacl g:rumpledumpleunknowngrp file1
-chacl: "g:rumpledumpleunknowngrp" is an invalid ACL specification.
-cannot find permission separator after char ":" (position 2)
+chacl: g:rumpledumpleunknowngrp - Invalid argument
 + chacl g:rumpledumpleunknowngrp: file1
-chacl: "g:rumpledumpleunknowngrp:" is an invalid ACL specification.
-cannot find group "rumpledumpleunknowngrp"
+chacl: g:rumpledumpleunknowngrp: - Invalid argument
 + chacl o:user1:rwx file1
-chacl: "o:user1:rwx" is an invalid ACL specification.
-garbage after other tag: "user1"
+chacl: o:user1:rwx - Invalid argument
 + chacl m:user1:rwx file1
-chacl: "m:user1:rwx" is an invalid ACL specification.
-garbage after mask tag: "user1"
+chacl: m:user1:rwx - Invalid argument
 + chacl a::rwx file1
-chacl: "a::rwx" is an invalid ACL specification.
-invalid tag: "a"
+chacl: a::rwx - Invalid argument
 + set +x