官方身份2示例项目的代码如下 UserManager.Create()
public static UserManager Create(IdentityFactoryOptions<UserManager> options, IOwinContext context) {
//...etc...
// --- what does this block do? ---
var dataProtectionProvider = options.DataProtectionProvider;
if (dataProtectionProvider != null) {
manager.UserTokenProvider = new DataProtectorTokenProvider<User>(dataProtectionProvider.Create("ASP.NET Identity"));
}
// --------------------------------
//...etc...
}
Run Code Online (Sandbox Code Playgroud)
alpha/beta/RTM Identity文档很糟糕或根本不存在.
这是做什么的?