Unix/Linux Go Back    


UNIX and Linux Applications Discuss UNIX and Linux software applications. This includes SQL, Databases, Middleware, MOM, SOA, EDA, CEP, BI, BPM and similar topics.

LDAP Group query

UNIX and Linux Applications


Tags
ldap group query

Closed    
 
Thread Tools Search this Thread Display Modes
    #1  
Old Unix and Linux 07-09-2015
jhamaks jhamaks is offline
Registered User
 
Join Date: Mar 2013
Last Activity: 9 July 2015, 3:06 PM EDT
Posts: 19
Thanks: 10
Thanked 0 Times in 0 Posts
LDAP Group query

I need to write LDAP group query where I need to find if a particular user is a member of a 2 specific Groups. This is LDAP Novell edirectory implementation.

Below are the details -
================

LDIF entry for OndotAPI group
dn: cn=OndotAPI,ou=Groups,o=CNS
changetype: add
objectClass: top
objectClass: groupOfNames
objectClass: CCGroupApplication
cn: OndotAPI

# OndotAPI, Groups, CNS
dn: cn=OndotAPI,ou=Groups,o=CNS
member: cn=OndotUsr,ou=WebServices,o=fiserveft
member: uid=test1113,ou=People,o=CNS
member: uid=rtest901,ou=People,o=CNS
member: cn=OndotUsr2,ou=WebServices,o=fiserveft

AND

LDIF entry for CREATE_SESSION role. Notice the user OndotUsr is also a member of that role.
dn: cn=CREATE_SESSION,ou=Groups,o=CNS
changetype: add
objectClass: top
objectClass: groupOfNames
objectClass: CCGroupRole
cn: CREATE_SESSION

# CREATE_SESSION, Groups, CNS
dn: cn=CREATE_SESSION,ou=Groups,o=CNS
member: cn=OndotUsr,ou=WebServices,o=fiserveft
member: uid=test1113,ou=People,o=CNS
member: uid=rtest901,ou=People,o=CNS
member: cn=OndotUsr2,ou=WebServices,o=fiserveft

So I need to verify using LDAP query that OndotUsr is a member of both the group - OndotAPI and CREATE_SESSION.

If this sounds difficult, then i need to write two queries one after the another in my program.
1) 1st query to see if OndotUsr is member of OndotAPI
2) if Yes, then only it'll run second query.
2n query to find if the OndotUsr is member of CREATE_SESSION group.

Need your help in writing this query.

Thank you.
Sponsored Links
Closed

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Linux More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
LDAP and AD Authentication Query Shirishlnx Emergency UNIX and Linux Support 2 06-03-2014 03:01 PM
Solaris LDAP group problem cjhilinski Solaris 3 03-26-2014 08:21 AM
Ldap search query posner Shell Programming and Scripting 1 08-13-2012 07:41 PM
LDAP search query help dopple UNIX for Dummies Questions & Answers 3 10-23-2008 10:06 AM
Perl and Net::LDAP, objects and arrays query mikie Shell Programming and Scripting 3 08-22-2008 03:05 PM



All times are GMT -4. The time now is 04:47 PM.