/// <summary>
 ///
 /// </summary>
 /// <param name="next"></param>
 /// <param name="tenantConfiguration"></param>
 /// <param name="hostingEnvironment"></param>
 /// <param name="handlerProvider"></param>
 public AuthContextMiddleware(
     RequestDelegate next,
     ITenantConfiguration tenantConfiguration,
     IHostingEnvironment hostingEnvironment,
     IAuthenticationHandlerProvider handlerProvider)
 {
     _next = next;
     _tenantConfiguration = tenantConfiguration;
     _hostingEnvironment  = hostingEnvironment;
     _handlerProvider     = handlerProvider;
 }
Exemplo n.º 2
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="interaction"></param>
 /// <param name="schemeProvider"></param>
 /// <param name="events"></param>
 /// <param name="tenants"></param>
 public AccountsController(
     IIdentityServerInteractionService interaction,
     IAuthenticationSchemeProvider schemeProvider,
     IEventService events,
     ITenantConfiguration tenants)
 {
     _interaction    = interaction;
     _schemeProvider = schemeProvider;
     _events         = events;
     _tenants        = tenants;
 }
Exemplo n.º 3
0
        public TenantEngine(ITenantConfiguration configuration, IInstanceStore instanceStore)
        {
            if (configuration == null)
            {
                throw new ArgumentNullException("configuration");
            }

            if (instanceStore == null)
            {
                throw new ArgumentNullException("instanceStore");
            }

            this.configuration    = configuration;
            this.runningInstances = instanceStore;
        }
Exemplo n.º 4
0
        public TenantEngine(ITenantConfiguration configuration, IInstanceStore instanceStore)
        {
            if (configuration == null)
            {
                throw new ArgumentNullException("configuration");
            }

            if (instanceStore == null)
            {
                throw new ArgumentNullException("instanceStore");
            }

            this.configuration = configuration;
            this.runningInstances = instanceStore;
        }
Exemplo n.º 5
0
 /// <summary>
 /// Create an instance of this class.
 /// </summary>
 /// <param name="configuration">Application configuration properties.</param>
 /// <param name="httpContextAccessor">Class for accessing the HTTP context.</param>
 /// <exception cref="ArgumentNullException">httpContextAccessor or it's associated context is null.</exception>
 public HostHeaderTenantResolver(ITenantConfiguration configuration, IHttpContextAccessor httpContextAccessor)
 {
     _config      = configuration ?? throw new ArgumentNullException(nameof(configuration));
     _httpContext =
         httpContextAccessor?.HttpContext ?? throw new ArgumentNullException(nameof(httpContextAccessor));
 }
Exemplo n.º 6
0
 /// <summary>
 /// Initializes a new instance of <see cref="ProfileClaims"/>
 /// </summary>
 /// <param name="tenantConfiguration"></param>
 public ProfileClaims(ITenantConfiguration tenantConfiguration)
 {
     _tenantConfiguration = tenantConfiguration;
 }
Exemplo n.º 7
0
 public TenantEngine(ITenantConfiguration configuration)
     : this(configuration, new MemoryCacheInstanceStore(InstanceLifetimeOptions.Default))
 {
 }
Exemplo n.º 8
0
 public TenantEngine(ITenantConfiguration configuration)
     : this(configuration, new MemoryCacheInstanceStore(InstanceLifetimeOptions.Default))
 { }