Thank you Joe for your reply.
Is it possible to get the user AD information like groups, first name, last
name, etc.. by passing only the user id? Or I need user id and password?
Any code sample would be helpful. Thanks.
> The filter would look like:
>
[quoted text clipped - 9 lines]
> > is
> > a way to filter the search by the user email address in AD? Thanks!
Joe Kaplan (MVP - ADSI) - 26 Aug 2005 18:19 GMT
It is possible to search for the user in AD given only their username and
you can get all of this information (although groups can be tricky).
However, you need a security context that has rights to access AD. If you
want to access AD using the user's own security context, you either need
their plain text credentials or a Windows security token that you can use to
impersonate them and access AD. If you want to use a different account to
access AD, then any valid service account that has the rights you need will
do.
So, it depends on what your model for accessing AD is.
There are lots of code samples in the System.DirectoryServices SDK topic in
MSDN.
Joe K.
> Thank you Joe for your reply.
>
[quoted text clipped - 19 lines]
>> > is
>> > a way to filter the search by the user email address in AD? Thanks!