Skip to Content
author's profile photo Former Member
Former Member

Searching LDAP using UME APIs

I am trying to search fro users in LDAP using UME APIs and I encountered the following


I modified the dataSourceConfiguration.XML to search for Custom LDAP Attributes. I added a New attribute called exportControlData in the XML.

1. How do I search for Multiple Attributes? For example I want to search for

UserId=100* , department="XYZ" and exportControlData ="y"

2. How do I retrieve the value for those Custom


For example I search for UserID="100", then I use user.getDispalyName(), user.getEmail(),user.getDepartment() to get the values and dipslay in a table. I also need to display a custom Attribute called exportControlData for UserID=100.

3. When I do a wild card search for UserID (100*) I get SEARCH_RESULT_UNDEFINED. I can successfully do a wild card search lastname, first Name.

Is there a way how I can get this working?



Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • author's profile photo Former Member
    Former Member
    Posted on Jun 08, 2004 at 05:11 PM

    To display a custom attribute you need to use code similar to:

    String expData[] = user.getAttribute(IPrincipal.DEFAULT_NAMESPACE,"exportControlData");

    if (expData != null)

    displayInfo("Export Data:" , expData[0]);

    You need to have the datasource_xxx.xml file configured to include the attribute:

    <principal type="user">


    <nameSpace name="">


    <attribute name="firstname" populateInitially="true" />

    <attribute name="displayname" populateInitially="true" />

    <attribute name="lastname" populateInitially="true" />

    . . .

    <attribute name="uniquename" populateInitially="true" />

    <attribute name="exportControlData" />



    <nameSpace name="">







    To search for Attribute:

    IUserSearchFilter userFilt =





    ISearchResult result = userFact.searchUsers(userFilt);


    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.