> Hello,
> I'm trying to generate a list of groups/OU's to which a user belongs
> through ADSI and am having problems. My AD looks like
>
> DC=FOO,DC=COM
> ---OU=OrgUnit1
> -------CN=GlobalSecurityGroup1
> ------------------member=CN=User1,OU=OrgUnit1,DC=FOO,DC=COM
> ------------------member=CN=User2,OU=OrgUnit1,DC=FOO,DC=COM
> ------------------member=CN=User3,OU=OrgUnit1,DC=FOO,DC=COM
> -------CN=User1
> -------CN=User2
> -------CN=User3
> -------CN=BuiltIn
> -------CN=Users
>
> So I have a top level OU which contains 3 users, User1,User2 and User3.
> The
> OU also contains GlobalSecurityGroup1 which has three members, User1,User2
> and User3.
>
> How can I use ADSI to generate a list of OUs/Groups to which User2
> belongs?
> I'd like to get a result set of GlobalSecurityGroup1 and OrgUnit1?
>
> I'm able to search DC=FOO,DC=COM and specify the following filter
>
>
member:1.2.840.113556.1.4.1941:=CN=User2,OU=OrgUnit1,DC=FOO,DC=COM
>
> which will return the NT Security Group, but not OrgUnit1, do I need two
> different queries?
>
>
> Thanks!
> Michael
>