Search code examples
asp.netactive-directoryasp.net-membershipasp.net-profiles

ASP.NET Active Directory Membership Provider - Storing Extra Profile Fields in AD


I have set up an Active Directory Membership provider and can successfully create and log in users into the active directory with an ASP.NET application.

However, the active directory has other fields besides Username/Password such as First Name, Last Name , Telephone Number etc. Is there any way for me to be able to gather this information using my ASP.NET website and store it in the Active Directory?

I understand that I need to use a Profile Provider and I can technically set it up to use an SQL DB to store the extra profile information, but is there any way I can store the information directly in the fields available in the Active Directory? As far as I know there is no ActiveDirectoryProfileProvider.

Thank you,


Solution

  • You could get there -- probably would need to step outside the membership system and use the System.DirectoryServices to write to AD. Now, writing to SQL will be a lot easier, especially at development time. And you won't have to fight a sysadmin who doesn't want your web app having elevated AD privileges.