Quantcast
Channel: .NET Framework Class Libraries forum
Viewing all articles
Browse latest Browse all 8156

Finding people in an active directory group

$
0
0

I code:

DirectoryEntry root = new DirectoryEntry("GC://dc=xxx,dc=com");
DirectorySearcher searcher = new DirectorySearcher(root);
searcher.Filter = string.Format("(&(objectCategory=group)(cn={0}))", mygroup);
searcher.PropertiesToLoad.AddRange( new[] { "member" });

The result is CN=S-1-5-21-302632946-1819051520-297497296-2925,CN=ForeignSecurityPrincipals,DC=xxx,DC=com

How do I get from this identifier to a person record?


Certified Geek





Viewing all articles
Browse latest Browse all 8156

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>