directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Emmanuel Lecharny (JIRA)" <>
Subject [jira] [Commented] (DIRAPI-288) Space between LDAP filter conditions causes NPE
Date Sat, 14 Jan 2017 01:17:26 GMT


Emmanuel Lecharny commented on DIRAPI-288:


I have committed some changes in the way we deal with filters, allowing spaces to be used.
Can you give it a try ?

> Space between LDAP filter conditions causes NPE
> -----------------------------------------------
>                 Key: DIRAPI-288
>                 URL:
>             Project: Directory Client API
>          Issue Type: Bug
>    Affects Versions: 1.0.0-M32, 1.0.0-RC2
>         Environment: Win7 x64 Java 1.7.0_51 - Query against Active Directory 2008
>            Reporter: Carlo Accorsi
>            Priority: Minor
> Hi, When setting a filter on a request having multiple conditions, if there are spaces
after operators or between clauses, this causes a NullPointerException. I'm not sure but I
think the spec ignores this type of white space. I tested the same problematic query with
JNDI and it executes without issue. I don't think the backend LDAP vendor matters, it seems
to fail in the api before the request is sent. 
> Query with no spaces between parenthetical conditions or after logical OR '|' and the
query executes as expected.
> (|(memberOf=cn=group1,ou=test)(memberOf=cn=group2,ou=test))
> Having a space after the logical OR operator and/or between conditions (not sure which)
throws NPE.
> Structure a query like this to reproduce where ^=space
> (|^(memberOf=cn=group1,ou=test)^(memberOf=cn=group2,ou=test))
> Found in api ver M32 and tested also in RC2.. 
> 	at Source) [na:1.7.0_51]
> Caused by: java.lang.NullPointerException: null
> 	at
> 	at
> 	at
> 	at
> 	at org.apache.mina.filter.codec.ProtocolCodecFilter.filterWrite(
> 	... 53 common frames omitted
> java.lang.NullPointerException
> Thanks for all your hard work and happy holidays!

This message was sent by Atlassian JIRA

View raw message