unrecognized objectIdentifer in desc form shall result in

an undefined matched.  unrecognized objectIdentifer in OID form
shall result in false match.
This commit is contained in:
Kurt Zeilenga 2000-06-19 20:53:56 +00:00
parent 665272dca1
commit 3bacb800d4
2 changed files with 13 additions and 3 deletions

View File

@ -36,7 +36,18 @@ objectClassMatch(
ObjectClass *oc = oc_find( value->bv_val );
ObjectClass *asserted = oc_find( a->bv_val );
if( asserted == NULL || oc == NULL ) {
if( asserted == NULL ) {
if( isdigit( *value.bv_val ) ) {
/* OID form, return FALSE */
*matchp = 1;
return LDAP_SUCCESS;
}
/* desc form, return undefined */
return LDAP_CONSTRAINT_VIOLATION;
}
if ( oc == NULL ) {
return LDAP_CONSTRAINT_VIOLATION;
}

View File

@ -187,8 +187,7 @@ int value_find(
rc = value_match( &match, ad, mr, vals[i],
nval == NULL ? val : nval, &text );
if( rc == LDAP_SUCCESS && match == 0 )
{
if( rc == LDAP_SUCCESS && match == 0 ) {
return LDAP_SUCCESS;
}
}