I am successfully using some simple LDAPSEARCH + LDAPGROUP searches to produce membership lists for various AD groups.
Ex.
| ldapsearch search="(&(objectClass=Group)(cn=Remote Desktop Users)"
| table cn,distinguishedName
| ldapgroup
| table cn,member_name,member_type
The searches work, but always show me all possible membership types (DIRECT, NESTED, etc.)
I would like to filter my end results so that only DIRECT members are returned.
I've tried inserting a | WHERE clause after the LDAPGROUP or final table command, but it just returns an empty set.
I'm clearly not quite understanding how to pipeline output correctly. Any help is much appreciated.
... View more