webMethods

webMethods

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  get user list / LDAP

    Posted Fri August 21, 2009 07:10 PM

    Where can I find the class/methods to get at the user list that is used by the Administration? I am looking at portlet and working with directory set such as being able to bring up user list that we have hooked up via LDAP through MWS.


    #MWS-CAF-Task-Engine
    #webMethods-BPMS
    #webMethods


  • 2.  RE: get user list / LDAP

    Posted Mon August 24, 2009 01:25 PM

    Hi
    have a look into the classes under the Common Directory Services API
    [url]http://www.ajax-softwareag.com/articles/Y4LCDN/Caf-7-1-1JavaDocs/com/webmethods/sc/directory/package-summary.html[/url].
    One example on using them:

    IDirectorySystem directorySystem = DirectorySystemFactory.getDirectorySystem();
    /* Create a Directory Session to access the directory services */
    IDirectorySession session = directorySystem.createSession();
    IDirectoryPrincipal ownerUser = session.lookupPrincipalByName(
    "fga", IDirectoryPrincipal.TYPE_USER);

    Unfortunately, the Common Directory Services API will not deliver you the users in a role defined by an LDP query (in case you are looking for that).

    hope this helps
    Javier


    #webMethods-BPMS
    #MWS-CAF-Task-Engine
    #webMethods


  • 3.  RE: get user list / LDAP

    Posted Wed August 01, 2012 08:01 AM

    Hi,

    Try

    user = ds.lookupPrincipalByDN(dn, IDirectoryPrincipal.TYPE_USER);

    where dn is Distinguished Name from ldap for example “uid=piotrw,ou=people,dc=itg,dc=pl”

    It`s work fine.

    Best Regards
    Peter


    #webMethods
    #webMethods-BPMS
    #MWS-CAF-Task-Engine