improve fix to ITS#2923; note that suffix massaging is inherently flawed, because comperisons should always occur on Normalized DN, while massaging can also occur on Pretty DN, but there is no guarantee they have the same length or any length-based comparison can work; so in any case, we should pass the Normalized DN and, if the Pretty DN is present, massage it as well accordingly

This commit is contained in:
Pierangelo Masarati 2004-01-17 12:25:46 +00:00
parent 2c049ebb42
commit d65f402058
2 changed files with 2 additions and 2 deletions

View File

@ -144,7 +144,7 @@ ldap_back_search(
dc.ctx = "searchBase";
#else
dc.tofrom = 1;
dc.normalized = 1;
dc.normalized = 0;
#endif
if ( ldap_back_dn_massage( &dc, &op->o_req_ndn, &mbase ) ) {
send_ldap_result( op, rs );

View File

@ -135,7 +135,7 @@ ldap_back_dn_massage(
/* At a DN Separator */
}
if ( !strcmp( dc->rwmap->rwm_suffix_massage[i+src].bv_val, &dn->bv_val[diff] ) ) {
if ( !strcasecmp( dc->rwmap->rwm_suffix_massage[i+src].bv_val, &dn->bv_val[diff] ) ) {
res->bv_len = diff + dc->rwmap->rwm_suffix_massage[i+dst].bv_len;
res->bv_val = ch_malloc( res->bv_len + 1 );
strncpy( res->bv_val, dn->bv_val, diff );