ASP.NET 2.0 introduced the Membership, Roles and Profile services. Developers could leverage these powerful services and rapidly add membership functionality to their sites. This was a great leap forward but did not address Web2.0, that is, there was no out of the box support for these services from an Ajax perspective. If you wanted to add Ajax type membership functionality the developer had to write ASMX or WCF services that wrapped these API calls. Then came along ASP.NET 3.5. In this release Microsoft shipped a set of Ajax enabled WCF services for the Membership, Roles and Profile services. Adding Ajax support was as simple as adding a few lines of XML to the web.config.
I just recently added Ajax support for the membership services to a local community web site. As advertised, just add a few lines of XML to the web.config and magically you can asynchronously log in or log out. This was wonderful. Then I decided to add support for registering users and then discovered there was no asynchronous equivalent to the CreateUser API. Why was this API not included? Are there security issues exposing this API?
The Ajax Membership API's are located in the assembly C:\Program Files\Reference Assemblies\Microsoft\Framework\v3.5\System.Web.Extensions.dll. Using every .NET developers trusted friend, reflector, we see that AuthenticationService class contains the following methods;
Where is the CreateUser method? It appears as though it was not included. Why I ask, why was it not included? I guess we still have to resort to writing custom Ajax enabled Membership WCF services!