标签:aac copy ram minimum imsi ova als 保存 相交
在需要进行表单认证的Asp.NET 5 MVC项目被创建后,往往需要根据项目的实际需求做一系列的工作对MVC 5内建的身份验证机制(Asp.NET Identity)进行扩展和定制:
总之,一切都是为了减轻管理的负担,提升工作效率,使项目整体变得更加优雅。
本文仅聚焦在表单身份认证(Forms Authentication)的个性化定制
CREATE TABLE [dbo].[User]
(
[Id] [bigint] IDENTITY(1,1) NOT NULL,
[Login] [nvarchar](50) NOT NULL,
[EMail] [nvarchar](255) NOT NULL,
[Password] [nvarchar](500) NULL,
[CreationDate] [datetime] NULL,
[ApprovalDate] [datetime] NULL,
[LastLoginDate] [datetime] NULL,
[IsLocked] [bit] NOT NULL,
[PasswordQuestion] [nvarchar](max) NULL,
[PasswordAnswer] [nvarchar](max) NULL,
[ActivationToken] [nvarchar](200) NULL,
[EmailConfirmed] [bit] NOT NULL,
[SecurityStamp] [nvarchar](max) NULL,
[PhoneNumber] [nvarchar](50) NULL,
[PhoneNumberConfirmed] [bit] NOT NULL,
[TwoFactorEnabled] [bit] NOT NULL,
[LockoutEndDateUtc] [datetime2](7) NULL,
[LockoutEnabled] [bit] NOT NULL,
[AccessFailedCount] [int] NOT NULL,
CONSTRAINT [PK_User] PRIMARY KEY CLUSTERED
(
[Id] ASC
),
CONSTRAINT [UX_User_EMail] UNIQUE NONCLUSTERED
(
[EMail] ASC
),
CONSTRAINT [UX_User_Login] UNIQUE NONCLUSTERED
(
[Login] ASC
)
)
GO
ALTER TABLE [dbo].[User] ADD CONSTRAINT [DF_User_IsLocked] DEFAULT ((0)) FOR [IsLocked]
GO
ALTER TABLE [dbo].[