开发者

Can Forms Authentication, Role Management and Data for the website all work from a single SQL database?

With ASP.NET 4 and Forms Authentication:

Is it possible to use one database to store data for:

  • Authentication of users (Using Forms authentication)
  • Role Management (Need Admins, and Member roles with various access levels)
  • Data used throughout the webis开发者_JS百科te, user preferences etc

I read that the database used as the Authentication provider needs to follow a specific schema, does this mean no other tables and data can be added to the SQL Database being used, or just that the tables storing data required for authentication need to be specific?


Yes, it is completely possible. All you need to do is run the script to register the required tables in your database.

This is easy to do using the ASP.NET SQL Server Registration Tool

The other data tables do not have to follow any specific schema and will not conflict with your ASP.NET tables unless you introduce some problematic data table relationships.


If you use default providers from ASP .NET they use predefined database schema but you can create your own providers which access database with their own way.


Yes you can use the same database you only need create cutom Role and Membership Providers so that you only have that data that is needed for you and not whole Aps.net default database

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜