[BACK]Return to ctime.test CVS log [TXT][DIR] Up to [Development] / xfs-cmds / xfstests / nfs4acl

File: [Development] / xfs-cmds / xfstests / nfs4acl / ctime.test (download)

Revision 1.1, Fri Sep 5 06:18:15 2008 UTC (9 years, 1 month ago) by tes.longdrop.melbourne.sgi.com
Branch: MAIN
CVS Tags: HEAD

Check in Andreas Gruenbacher's nfs v4 acl tests into the xfstests suite.
Merge of master-melb:xfs-cmds:32058a by kenmcd.

  Add in AG's nfs4acl tests.

$ mkdir d
$ cd d

$ whoami
> root

$ touch a b
$ sleep 1

Without write access, the ctime cannot be changed.
	$ su bin
	$ touch a
	> touch: cannot touch `a': Permission denied

With write access, the ctime can be set to the current time, but not to
any other time:
	$ su
	$ nfs4acl --set 'bin:rw::allow' a

	$ su bin
	$ touch a
	$ [ b -ot a ] || echo 'b should be older than a'
	$ touch -r b a
	> touch: setting times of `a': Operation not permitted

With set_attributes access, the ctime can be set to an arbitrary time:
	$ su
	$ nfs4acl --set 'bin:rwt::allow' a

	$ su bin
	$ touch -r b a
	$ [ b -ot a -o a -ot b ] && echo 'a should be as old as b'

$ su
$ cd ..
$ rm -rf d