mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-21 03:10:25 +08:00
Fixed segfault in caseIgnoreFilter when assertion value has bad UTF8 coding
This commit is contained in:
parent
e864abf685
commit
886a7575d0
@ -1869,6 +1869,12 @@ int caseIgnoreFilter(
|
||||
|
||||
#if UTF8MATCH
|
||||
value = ber_bvstr( UTF8normalize( ((struct berval *) assertValue)->bv_val, UTF8_CASEFOLD ) );
|
||||
/* This usually happens if filter contains bad UTF8 */
|
||||
if( value == NULL ) {
|
||||
keys = ch_malloc( sizeof( struct berval * ) );
|
||||
keys[0] = NULL;
|
||||
return LDAP_SUCCESS;
|
||||
}
|
||||
#else
|
||||
value = ber_bvdup( (struct berval *) assertValue );
|
||||
ldap_pvt_str2upper( value->bv_val );
|
||||
|
Loading…
Reference in New Issue
Block a user