Exemplo n.º 1
0
        public UserStore(
            DataStore store,
            IPasswordHasher <TUser> passwordHasher,
            RoleManager <TRole> roles,
            IQueryableProvider <TUser> queryable,
            IIdentityClaimNameProvider claimNameProvider,
            ISuperUserInfoProvider superUserInfoProvider,
            ILookupNormalizer lookupNormalizer,
            IServiceProvider serviceProvider)
        {
            serviceProvider.TryGetRequestAbortCancellationToken(out var cancellationToken);
            serviceProvider.TryGetTenantId(out _tenantId);
            serviceProvider.TryGetTenantName(out _tenantName);
            serviceProvider.TryGetApplicationId(out _applicationId);
            serviceProvider.TryGetApplicationName(out _applicationName);

            CancellationToken = cancellationToken;

            _store          = store;
            _passwordHasher = passwordHasher;
            _roles          = roles;
            _queryable      = queryable;

            _claimNameProvider     = claimNameProvider;
            _superUserInfoProvider = superUserInfoProvider;
            _lookupNormalizer      = lookupNormalizer;
        }
 public SuperUserTokenController(IValidOptionsSnapshot <SuperUserOptions> options,
                                 ITokenFabricator <TKey> fabricator,
                                 IIdentityClaimNameProvider claimNameProvider)
 {
     _options           = options;
     _fabricator        = fabricator;
     _claimNameProvider = claimNameProvider;
 }
 public CookiesSignInHandler(IHttpContextAccessor http, IAuthenticationService authentication,
                             IIdentityClaimNameProvider claimNameProvider,
                             ICookiesInfoProvider cookiesInfoProvider)
 {
     _http                = http;
     _authentication      = authentication;
     _claimNameProvider   = claimNameProvider;
     _cookiesInfoProvider = cookiesInfoProvider;
 }