Ejemplo n.º 1
0
 public CookiesIdentityAuthenticationService(
     IHttpContextAccessor httpContextAccessor,
     CookiesConfiguration configuration)
 {
     _httpContextAccessor = httpContextAccessor;
     _configuration       = configuration;
 }
Ejemplo n.º 2
0
        private void SetDefaultsFromConfig()
        {
            CookiesConfiguration cookiesConfig = ServerConfig.GetConfig().Cookies;

            if (cookiesConfig != null)
            {
                this.secure   = cookiesConfig.RequireSSL;
                this.httpOnly = cookiesConfig.HttpOnlyCookies;

                if (!string.IsNullOrEmpty(cookiesConfig.Domain))
                {
                    this.domain = cookiesConfig.Domain;
                }
            }
        }