mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-12-24 00:29:35 -05:00
In backend_group, return LDAP_COMPARE_FALSE if attr exists but value is
not matched, instead of LDAP_NO_SUCH_ATTRIBUTE
This commit is contained in:
parent
642b788fb2
commit
6a2d53f396
2 changed files with 7 additions and 4 deletions
|
|
@ -1281,7 +1281,7 @@ backend_group(
|
|||
}
|
||||
|
||||
if ( rc == 0 ) {
|
||||
rc = 1;
|
||||
rc = LDAP_COMPARE_FALSE;
|
||||
for ( i = 0; !BER_BVISNULL( &a->a_vals[i] ); i++ ) {
|
||||
if ( ldap_url_parse( a->a_vals[i].bv_val, &ludp ) !=
|
||||
LDAP_URL_SUCCESS )
|
||||
|
|
@ -1354,6 +1354,8 @@ loopit:
|
|||
SLAP_MR_ATTRIBUTE_VALUE_NORMALIZED_MATCH |
|
||||
SLAP_MR_ASSERTED_VALUE_NORMALIZED_MATCH,
|
||||
a->a_nvals, op_ndn, op->o_tmpmemctx );
|
||||
if ( rc == LDAP_NO_SUCH_ATTRIBUTE )
|
||||
rc = LDAP_COMPARE_FALSE;
|
||||
}
|
||||
} else {
|
||||
rc = LDAP_NO_SUCH_ATTRIBUTE;
|
||||
|
|
|
|||
|
|
@ -64,10 +64,11 @@ dyngroup_response( Operation *op, SlapReply *rs )
|
|||
int cache = op->o_do_not_cache;
|
||||
|
||||
op->o_do_not_cache = 1;
|
||||
if ( backend_group( op, NULL, &op->o_req_ndn,
|
||||
&op->oq_compare.rs_ava->aa_value, NULL, ap->ap_uri ) == 0 )
|
||||
rs->sr_err = LDAP_COMPARE_TRUE;
|
||||
rs->sr_err = backend_group( op, NULL, &op->o_req_ndn,
|
||||
&op->oq_compare.rs_ava->aa_value, NULL, ap->ap_uri );
|
||||
op->o_do_not_cache = cache;
|
||||
if ( rs->sr_err == LDAP_SUCCESS )
|
||||
rs->sr_err = LDAP_COMPARE_TRUE;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue