LDAP Error "Unbalanced parenthesis"
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Problem
When logging in using an LDAP user account, the following error occurs:
1
2
3
4
Test retrieve user: Failed
org.springframework.ldap.InvalidSearchFilterException: Unbalanced parenthesis; nested exception is
javax.naming.directory.InvalidSearchFilterException: Unbalanced
parenthesis; remaining name
The following appears in the atlassian-fisheye-YYYY-MM-DD.log
:
1
2
3
4
5
6
7
8
9
10
2016-03-25 17:14:03,161 ERROR [qtp1342346098-355 ] fisheye
DefaultUserManager-loginWithSanitizedUserName - Could not authenticate
user "UserName"
com.cenqua.fisheye.user.AuthenticationException: com.atlassian.crowd.exception.runtime.OperationFailedException
...
Caused
by: org.springframework.ldap.InvalidSearchFilterException: Unbalanced
parenthesis; nested exception is
javax.naming.directory.InvalidSearchFilterException: Unbalanced
parenthesis; remaining name...
Cause
User Object Filter requires that the value be enclosed in parentheses. By default this is not an issue as the default values already include parentheses.
Versions of Fisheye prior to 4.0 allowed the User Object Filter to be specified without parentheses.
Resolution
Add parentheses to the value of User Object Filter.
Example:

Was this helpful?