]> git.sur5r.net Git - openldap/commitdiff
Added a "dnattr" case for ACIs (still need to check the ACI OID).
authorMark Valence <mrv@openldap.org>
Mon, 8 Nov 1999 18:50:51 +0000 (18:50 +0000)
committerMark Valence <mrv@openldap.org>
Mon, 8 Nov 1999 18:50:51 +0000 (18:50 +0000)
servers/slapd/acl.c

index 9905c9dca39c67e6e0842bbae16b1028616fd471..ac2500cf4d82846257d47218fbfee05a0270b0c0 100644 (file)
@@ -994,6 +994,22 @@ aci_mask (
                if (strcasecmp(op->o_ndn, e->e_ndn) == 0)
                        return(1);
 
+       } else if (aci_strbvcmp( "dnattr", &bv ) == 0) {
+               Attribute *at;
+               char *attrname;
+
+               attrname = aci_bvstrdup(&sdn);
+               at = attr_find(e->e_attrs, attrname);
+               ch_free(attrname);
+
+               if (at != NULL) {
+                       bv.bv_val = op->o_ndn;
+                       bv.bv_len = strlen( bv.bv_val );
+
+                       if (value_find( at->a_vals, &bv, at->a_syntax, 3 ) == 0 )
+                               return(1);
+               }
+
        } else if (aci_strbvcmp( "group", &bv ) == 0) {
                if (aci_group_member(&sdn, "groupOfNames", "member", be, e, op, matches))
                        return(1);