0

I'm trying to make a ldap query which I can run in active directory tool, so I can have an overview of all users with their groups.

What do I need to add to this script to see the groups of these users ?

&(objectCategory=person)(objectClass=user) (givenName=)(sn=))

Thanks,

Joep
  • 1
  • 1
  • 1

1 Answers1

3

This is not a script, this is a LDAP filter which means :

(&(objectCategory=person)(objectClass=user)(givenName=*)(sn=*))

Retrieve the entries which are of the type person AND user AND which possess these attributes populated : givenName AND sn

If you want to retrieve the groups which these users are member of, configure on the tool that you want to also retrieve the attribute memberOf from the users entries filtered.

As stated in the Subject of the question, if you want to know the members of the group MyGroupName, retrieve the member attribute of this group filtered by a LDAP filter, for example, such as :

(&(objectClass=groupOfUniqueNames)(cn=MyGroupName))

Esteban
  • 286
  • 1
  • 7