]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/aci.c
fix dirsep's in DN (ITS#5172)
[openldap] / servers / slapd / aci.c
index 2ed91c4935d8901b024005f408dccbc4c89d4d57..0acf6c108ff38848a953c28454866a33390b613c 100644 (file)
@@ -278,18 +278,31 @@ aci_list_get_attr_rights(
        ACL_INIT(mask);
        for ( i = 1; acl_get_part( list, i + 1, ';', &bv ) >= 0; i += 2 ) {
                if ( aci_list_has_attr( &bv, attr, val ) == 0 ) {
-                       Debug( LDAP_DEBUG_ACL, "        <= aci_list_get_attr_rights test %s for %s -> failed\n", bv.bv_val, attr->bv_val, 0 );
+                       Debug( LDAP_DEBUG_ACL,
+                               "        <= aci_list_get_attr_rights "
+                               "test %s for %s -> failed\n",
+                               bv.bv_val, attr->bv_val, 0 );
                        continue;
                }
-               Debug( LDAP_DEBUG_ACL, "        <= aci_list_get_attr_rights test %s for %s -> ok\n", bv.bv_val, attr->bv_val, 0 );
+
+               Debug( LDAP_DEBUG_ACL,
+                       "        <= aci_list_get_attr_rights "
+                       "test %s for %s -> ok\n",
+                       bv.bv_val, attr->bv_val, 0 );
 
                if ( acl_get_part( list, i, ';', &bv ) < 0 ) {
-                       Debug( LDAP_DEBUG_ACL, "        <= aci_list_get_attr_rights test no rightsk\n", 0, 0, 0 );
+                       Debug( LDAP_DEBUG_ACL,
+                               "        <= aci_list_get_attr_rights "
+                               "test no rights\n",
+                               0, 0, 0 );
                        continue;
                }
 
                mask |= aci_list_map_rights( &bv );
-               Debug( LDAP_DEBUG_ACL, "        <= aci_list_get_attr_rights rights %s to mask 0x%x\n", bv.bv_val, mask, 0 );
+               Debug( LDAP_DEBUG_ACL,
+                       "        <= aci_list_get_attr_rights "
+                       "rights %s to mask 0x%x\n",
+                       bv.bv_val, mask, 0 );
        }
 
        return mask;
@@ -579,11 +592,10 @@ aci_mask(
                                at != NULL;
                                at = attrs_find( at->a_next, ad ) )
                {
-                       if ( value_find_ex( ad,
+                       if ( attr_valfind( at, 
                                SLAP_MR_ATTRIBUTE_VALUE_NORMALIZED_MATCH |
                                        SLAP_MR_ASSERTED_VALUE_NORMALIZED_MATCH,
-                               at->a_nvals,
-                               &op->o_ndn, op->o_tmpmemctx ) == 0 )
+                               &op->o_ndn, NULL, op->o_tmpmemctx ) == 0 )
                        {
                                rc = 1;
                                break;
@@ -663,6 +675,7 @@ aci_init( void )
        static slap_syntax_defs_rec aci_syntax_def = {
                "( 1.3.6.1.4.1.4203.666.2.1 DESC 'OpenLDAP Experimental ACI' )",
                        SLAP_SYNTAX_HIDE,
+                       NULL,
                        OpenLDAPaciValidate,
                        OpenLDAPaciPretty
        };