Пример #1
0
 public IdentityProviderProvider(IOptionsMonitor <WsTrustOptions> monitor, ILogger <IdentityProviderProvider> logger, IIdentityProviderStore store = null)
 {
     Options             = monitor.CurrentValue;
     _optionsChangeToken = monitor.OnChange((options, _) => Options = options);
     _logger             = logger;
     _store = store;
 }
Пример #2
0
    /// <summary>
    /// Initializes a new instance of the <see cref="ValidatingIdentityProviderStore{T}" /> class.
    /// </summary>
    public ValidatingIdentityProviderStore(T inner, IIdentityProviderConfigurationValidator validator, IEventService events, ILogger <ValidatingIdentityProviderStore <T> > logger)
    {
        _inner     = inner;
        _validator = validator;
        _events    = events;
        _logger    = logger;

        _validatorType = validator.GetType().FullName;
    }
 /// <summary>
 /// Ctor
 /// </summary>
 public NonCachingIdentityProviderStore(T inner,
                                        IdentityServerOptions options,
                                        IHttpContextAccessor httpContextAccessor,
                                        ILogger <NonCachingIdentityProviderStore <T> > logger)
 {
     _inner               = inner;
     _options             = options;
     _httpContextAccessor = httpContextAccessor;
     _logger              = logger;
 }
 /// <summary>
 /// Ctor
 /// </summary>
 /// <param name="inner"></param>
 /// <param name="cache"></param>
 /// <param name="allCache"></param>
 /// <param name="options"></param>
 /// <param name="httpContextAccessor"></param>
 public CachingIdentityProviderStore(T inner,
                                     ICache <IdentityProvider> cache,
                                     ICache <IEnumerable <IdentityProviderName> > allCache,
                                     IdentityServerOptions options,
                                     IHttpContextAccessor httpContextAccessor)
 {
     _inner               = inner;
     _cache               = cache;
     _allCache            = allCache;
     _options             = options;
     _httpContextAccessor = httpContextAccessor;
 }
Пример #5
0
 public Index(
     IIdentityServerInteractionService interaction,
     IAuthenticationSchemeProvider schemeProvider,
     IIdentityProviderStore identityProviderStore,
     IEventService events,
     UserManager <ApplicationUser> userManager,
     SignInManager <ApplicationUser> signInManager)
 {
     _userManager           = userManager;
     _signInManager         = signInManager;
     _interaction           = interaction;
     _schemeProvider        = schemeProvider;
     _identityProviderStore = identityProviderStore;
     _events = events;
 }
Пример #6
0
 public Index(
     IIdentityServerInteractionService interaction,
     IClientStore clientStore,
     IAuthenticationSchemeProvider schemeProvider,
     IIdentityProviderStore identityProviderStore,
     IEventService events,
     SignInManager <IdentityUser> signInManager)
 {
     _interaction           = interaction;
     _clientStore           = clientStore;
     _schemeProvider        = schemeProvider;
     _identityProviderStore = identityProviderStore;
     _events        = events;
     _signInManager = signInManager;
 }
Пример #7
0
    public Index(
        IIdentityServerInteractionService interaction,
        IClientStore clientStore,
        IAuthenticationSchemeProvider schemeProvider,
        IIdentityProviderStore identityProviderStore,
        IEventService events,
        TestUserStore users = null)
    {
        // this is where you would plug in your own custom identity management library (e.g. ASP.NET Identity)
        _users = users ?? throw new Exception("Please call 'AddTestUsers(TestUsers.Users)' on the IIdentityServerBuilder in Startup or remove the TestUserStore from the AccountController.");

        _interaction           = interaction;
        _clientStore           = clientStore;
        _schemeProvider        = schemeProvider;
        _identityProviderStore = identityProviderStore;
        _events = events;
    }
Пример #8
0
 public AccountController(
     UserManager <ApplicationUser> userManager,
     SignInManager <ApplicationUser> signInManager,
     IIdentityServerInteractionService interaction,
     IClientStore clientStore,
     IAuthenticationSchemeProvider schemeProvider,
     IIdentityProviderStore identityProviderStore,
     IEventService events)
 {
     _userManager           = userManager;
     _signInManager         = signInManager;
     _interaction           = interaction;
     _clientStore           = clientStore;
     _schemeProvider        = schemeProvider;
     _identityProviderStore = identityProviderStore;
     _events = events;
 }
Пример #9
0
 /// <summary>
 /// Initializes a new instance of the <see cref="IdentityProviderController"/> class.
 /// </summary>
 /// <param name="store">The store.</param>
 /// <exception cref="System.ArgumentNullException">store</exception>
 public IdentityProviderController(IIdentityProviderStore store)
 {
     _store = store ?? throw new ArgumentNullException(nameof(store));
 }
 public AuthenticationSchemeRetriever(IOptionsMonitor <ExtendedAuthenticationOptions> authenticationOptionsMonitor, IAuthenticationSchemeLoader authenticationSchemeLoader, IIdentityProviderStore identityProviderStore, IOptionsMonitor <IdentityServerOptions> identityServerOptionsMonitor, ILoggerFactory loggerFactory)
 {
     this.AuthenticationOptionsMonitor = authenticationOptionsMonitor ?? throw new ArgumentNullException(nameof(authenticationOptionsMonitor));
     this.AuthenticationSchemeLoader   = authenticationSchemeLoader ?? throw new ArgumentNullException(nameof(authenticationSchemeLoader));
     this.IdentityProviderStore        = identityProviderStore ?? throw new ArgumentNullException(nameof(identityProviderStore));
     this.IdentityServerOptionsMonitor = identityServerOptionsMonitor ?? throw new ArgumentNullException(nameof(identityServerOptionsMonitor));
     this.Logger = (loggerFactory ?? throw new ArgumentNullException(nameof(loggerFactory))).CreateLogger(this.GetType());
 }