Messages in this thread | | | Subject | Re: [PATCH] VFS: document what MAY_ACCESS means | From | Trond Myklebust <> | Date | Mon, 21 Sep 2009 08:29:53 -0400 |
| |
On Mon, 2009-09-21 at 09:10 +0100, Jamie Lokier wrote > (Btw, side issue: I was very surprised to find fchdir() to an open > directory can fail on NFS due to change of permissions, so the pattern > dir = open("."); chdir("foo"); fchdir(dir) can fail to restore the > current directory).
Welcome to the world of stateless server-enforced security. Unlike the POSIX model, a NFS server doesn't have the ability to track what permissions have already been checked using a file descriptor. It therefore needs to check permissions on each RPC operation you perform using the credential you present then and there.
Cheers Trond
| |