Monday, November 11, 2013

Some LDAP queries for common use

LDAP QUERIES

AD/GC FOR GROUPS THAT A USER IS MEMBER OF

1. Find the DN of the user e.g.
CN=Rajan Katwal,CN=Users,DC=katwal,DC=local

2.Use the DN into following query
(&(objectCategory=group)(member=CN=Rajan Katwal,CN=Users,DC=katwal,DC=local))

------------------------------------------------------------------------------------------------

USERS MEMBER OF A SPCIFIC GROUP

(&(objectcategory=user)(memberof=CN=Katwal_DL,CN=Users,DC=katwal,DC=local))

------------------------------------------------------------------------------------------------

No comments: