Windows – What’s the AD query syntax to enumerate all users for a particular group

active-directoryldapwindows

Here's what does not work so far;

(&(objectCategory=Person)(objectClass=Group)(CN=group_in_question))

(&(objectClass=Group)(objectCategory=Group)(member=CN=group_in_question))

(&(samAccountName=%USERNAME%)(memberof=CN=group_in_question))

(&(objectCategory=person)(objectClass=user)(memberOf=cn=group_in_question,ou=Groups,dc=mydomain,dc=com))

Best Answer

The third syntax works fine for me in LDP.EXE against one of my domains. I don't normally put the (objectCategory=person) in there, but it works fine with it, too.

What kind of error are you getting back when you try to use that?