]> git.michaelhowe.org Git - packages/o/openafs.git/commitdiff
windows-freelance-20070131
authorJeffrey Altman <jaltman@secure-endpoints.com>
Thu, 1 Feb 2007 04:28:37 +0000 (04:28 +0000)
committerJeffrey Altman <jaltman@secure-endpoints.com>
Thu, 1 Feb 2007 04:28:37 +0000 (04:28 +0000)
FIXES 52069

If an app tries to open the freelance directory for WRITE then the
default anonymous access privileges, read/lookup, are not sufficient
and cm_HaveAccessRights will fail.  Freelance can't get access rights
from anywhere.  Therefore, cm_HaveAccessRights should special case
the Freelance directory.

src/WINNT/afsd/cm_access.c

index 3b16c101e54021bc3b8bd32b22c5fbc575f937f8..ba747a80869efcc2b7068dbd77e1fd0deb20b001 100644 (file)
@@ -76,6 +76,12 @@ int cm_HaveAccessRights(struct cm_scache *scp, struct cm_user *userp, afs_uint32
      * Otherwise, if we an explicit acl entry, we're also in good shape,
      * and can definitively answer.
      */
+#ifdef AFS_FREELANCE_CLIENT
+    if (cm_freelanceEnabled && aclScp == cm_data.rootSCachep)
+    {
+       *outRightsp = aclScp->anyAccess;
+    } else
+#endif
     if ((~aclScp->anyAccess & rights) == 0) {
         *outRightsp = rights;
     } else {