2 # vim: filetype=sh noexpandtab ts=8 sw=8
3 # $FreeBSD: head/tools/regression/pjdfstest/tests/granular/01.t 211352 2010-08-15 21:24:17Z pjd $
5 desc="NFSv4 granular permissions checking - ACL_READ_ATTRIBUTES and ACL_WRITE_ATTRIBUTES"
10 [ "${os}:${fs}" = "FreeBSD:ZFS" ] || quick_exit
18 expect 0 mkdir ${n2} 0755
22 # Tests 1..12 - check out whether user 65534 is permitted to read attributes.
23 expect 0 create ${n0} 0644
24 expect 0 lstat ${n0} size
25 expect 0 -u 65534 -g 65534 stat ${n0} size
26 expect 0 prependacl ${n0} user:65534:read_attributes::deny
27 expect 0 lstat ${n0} size
28 expect EACCES -u 65534 -g 65534 stat ${n0} size
29 expect 0 prependacl ${n0} user:65534:read_attributes::allow
30 expect 0 -u 65534 -g 65534 stat ${n0} size
31 expect 0 lstat ${n0} size
34 # Tests 12..12 - check out whether user 65534 is permitted to write attributes.
35 # XXX: Check if ACL_WRITE_ATTRIBUTES allows for modifying access times.