using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace OlympiaIntranet
{
    public partial class Default2 : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            //if (User.Identity.IsAuthenticated == false || User.Identity.Name == "external")
            if (User.Identity.IsAuthenticated == false) // [30-08-2024]: Rimossa utenza external su richiesta di Fede
            {
                Response.Redirect("~/SignIn.aspx");
            }
        }

        protected void lbLogout_Click(object sender, EventArgs e)
        {
            var AuthenticationManager = HttpContext.Current.GetOwinContext().Authentication;
            AuthenticationManager.SignOut();

            Response.Redirect("~/SignIn.aspx");
        }
    }
}