Esempio n. 1
0
        public async Task <ClaimsIdentity> GenerateUserIdentityAsync(FSMUserManager 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);
        }
Esempio n. 2
0
        public Task <ClaimsIdentity> GenerateUserIdentity(FSMUserManager manager, string authenticationType)
        {
            // Note the authenticationType must match the one defined in CookieAuthenticationOptions.AuthenticationType
            var userIdentity = manager.CreateIdentity <FSMIdentityUser, string>(this, authenticationType);

            // Add custom user claims here
            return(Task.FromResult(userIdentity));
        }
        protected override void Dispose(bool disposing)
        {
            if (disposing && _userManager != null)
            {
                _userManager.Dispose();
                _userManager = null;
            }

            base.Dispose(disposing);
        }
 public AccountController(FSMUserManager userManager,
                          ISecureDataFormat <AuthenticationTicket> accessTokenFormat)
 {
     UserManager       = userManager;
     AccessTokenFormat = accessTokenFormat;
 }