예제 #1
0
        public ClaimsIdentity CreateIdentity(User user, string authenticationType)
        {
            user.ThrowIfNull("user");
            authenticationType.ThrowIfNull("authenticationType");

            var appIdentityUser = IdentityModelFactory.Create(user);
            var claimsIdentity  = _userManager.CreateIdentity(appIdentityUser, authenticationType);

            user.CopyFrom(appIdentityUser);

            return(claimsIdentity);
        }