6

Windows 認証を使用して MVC アプリケーションを作成すると、データベース テーブルにロールとそうでないものが追加されます...プロジェクトを空のプロジェクトとして作成した場合、それらを手動で追加するにはどうすればよいですか?

私は実行しました:

C:\Windows\Microsoft.NET\Framework\v4.0.30319\aspnet_regsql.exe 

packagemanagerの内部ですが、古いバージョンを作成しました

aspnet_blabla

.... なんてこった、たくさんのテーブルとビューが追加されている (泣きながら眠る)

http://msdn.microsoft.com/en-us/library/ms229862(v=vs.100).aspx#findingthecorrectversionを見つけました。 これは、データベースにクレイジーを配置することになる通常のことをほとんど言っています。:'(

aspnet_blabla テーブルの使用に問題はありますか?

4

1 に答える 1

2

There are three main implementations of membership (and roles) in the default Microsoft stack. In order of coolness (i.e. newest to oldest), they are:

ASP.NET Identity

This is the new coolness, released in tandem with VS2013. It is a simplified system implemented with EF Code First, and should be pretty easy to plug into any project. Here is a walkthrough of doing just that. All of the project templates in VS2013 use this.

Simple Membership

Is a light-weight implementation of the Membership Provider model (more below). As the original implementation was cumbersome, this tried to alleviate some of that. It is more compatible with older WebForms stuff. This was the best link I could find.

ASP.NET Membership Provider

This is the model that shipped with .NET 2.0 and has a gigantic schema. You can create the schema in your database with the aspnet_regsql tool.

于 2013-12-17T03:52:15.153 に答える