]> git.sur5r.net Git - openldap/commitdiff
backout previous commit: frontendDB doesn't have the right rootn, ACLs and so
authorPierangelo Masarati <ando@openldap.org>
Fri, 22 Jul 2005 17:22:51 +0000 (17:22 +0000)
committerPierangelo Masarati <ando@openldap.org>
Fri, 22 Jul 2005 17:22:51 +0000 (17:22 +0000)
servers/slapd/acl.c

index e7dcc18ccdbed1d35aa990cb4d9abeed1b028e4c..7306baa294c125401a2d84052a48287f84a2d9ce 100644 (file)
@@ -359,7 +359,6 @@ access_allowed_mask(
        const char                      *attr;
        int                             st_same_attr = 0;
        static AccessControlState       state_init = ACL_STATE_INIT;
-       BackendDB                       *be_orig;
 
        assert( e != NULL );
        assert( desc != NULL );
@@ -430,15 +429,25 @@ access_allowed_mask(
        /* this is enforced in backend_add() */
        if ( op->o_bd->bd_info->bi_access_allowed ) {
                /* delegate to backend */
-               ret = op->o_bd->bd_info->bi_access_allowed( op, e, desc, val, access, state, &mask );
+               ret = op->o_bd->bd_info->bi_access_allowed( op, e,
+                               desc, val, access, state, &mask );
 
        } else {
-               /* use default (but pass through frontend for global ACL overlays) */
-               be_orig = op->o_bd;
+#if 0
+               /* FIXME: this doesn't work because frontendDB doesn't have
+                * the right rootn, ACLs and so. */
+               BackendDB       *be_orig;
 
+               /* use default (but pass through frontend
+                * for global ACL overlays) */
+               be_orig = op->o_bd;
                op->o_bd = frontendDB;
-               ret = frontendDB->bd_info->bi_access_allowed( op, e, desc, val, access, state, &mask );
+               ret = frontendDB->bd_info->bi_access_allowed( op, e,
+                               desc, val, access, state, &mask );
                op->o_bd = be_orig;
+#endif
+               ret = slap_access_allowed( op, e, 
+                               desc, val, access, state, &mask );
        }
 
        if ( !ret ) {