예제 #1
0
        public async Task <ClaimsIdentity> GenerateUserIdentityAsync(IAppUserManager manager, string authenticationType)
        {
            // Note the authenticationType must match the one defined in CookieAuthenticationOptions.AuthenticationType
            var userIdentity = await manager.CreateIdentityAsync(this, authenticationType);

            // Add custom user claims here
            return(userIdentity);
        }
예제 #2
0
 public override Task <ClaimsIdentity> CreateUserIdentityAsync(User user)
 {
     return(_userManager.CreateIdentityAsync(user, DefaultAuthenticationTypes.ApplicationCookie));
 }