protected override void OnPreInit(System.EventArgs e) { base.OnPreInit(e); if (!CheckRole.IsAuthenticated()) { SetErr.NotAuthenticated(); } }
protected override void OnPreInit(System.EventArgs e) { base.OnPreInit(e); // if session goes away then consider the user logged out if (Session[AllConstStrs.se_currentUser] == null) { FormsAuthentication.SignOut(); SetErr.NotAuthenticated(); System.Web.HttpContext.Current.Response.End(); } }
protected override void OnPreInit(System.EventArgs e) { base.OnPreInit(e); if (!CheckRole.IsAuthenticated()) { SetErr.NotAuthenticated(); } else if (!CheckRole.IsSuperAdmin()) { SetErr.Redirect(); } }
protected override void OnPreInit(System.EventArgs e) { base.OnPreInit(e); if (!CheckRole.IsAuthenticated()) { SetErr.NotAuthenticated(); } else if (!CheckRole.IsManagement()) { // redirect to error page SetErr.Redirect(); } }
protected override void OnPreInit(System.EventArgs e) { base.OnPreInit(e); if (System.Web.HttpContext.Current.Request.QueryString["sig"] != null) { var req = System.Web.HttpContext.Current.Request; //"/checkout/checkout.aspx?customer="+_custID+"&design="+Eval("DesignID")+"&reorder="+Eval("OrderID") //Hmac.SignUrl(message, System.DateTime.UtcNow.AddMinutes(10)); if (!Hmac.ValidateRequest(req.Url)) { SetErr.NotAuthenticated(); System.Web.HttpContext.Current.Response.End(); } } // if session goes away then consider the user logged out else if (Session[AllConstStrs.se_currentUser] == null) { FormsAuthentication.SignOut(); SetErr.NotAuthenticated(); System.Web.HttpContext.Current.Response.End(); } }