From: Kurt Zeilenga Date: Wed, 10 Sep 2003 02:33:36 +0000 (+0000) Subject: ITS#2707: fix 'access to dn.subtree="" by ...' directives X-Git-Tag: OPENLDAP_REL_ENG_2_1_MP~740 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=6f39517929fac4963298047a1665c062a1558a2d;p=openldap ITS#2707: fix 'access to dn.subtree="" by ...' directives --- diff --git a/servers/slapd/aclparse.c b/servers/slapd/aclparse.c index 195b5c88f5..581d447f11 100644 --- a/servers/slapd/aclparse.c +++ b/servers/slapd/aclparse.c @@ -169,8 +169,14 @@ parse_acl( } else if ( strcasecmp( style, "subtree" ) == 0 || strcasecmp( style, "sub" ) == 0 ) { - a->acl_dn_style = ACL_STYLE_SUBTREE; - ber_str2bv( right, 0, 1, &a->acl_dn_pat ); + if( *right == '\0' ) { + a->acl_dn_pat.bv_val = ch_strdup( "*" ); + a->acl_dn_pat.bv_len = 1; + + } else { + a->acl_dn_style = ACL_STYLE_SUBTREE; + ber_str2bv( right, 0, 1, &a->acl_dn_pat ); + } } else if ( strcasecmp( style, "children" ) == 0 ) { a->acl_dn_style = ACL_STYLE_CHILDREN;