Esempio n. 1
0
        protected virtual bool CheckAccess(AuthorizationContext filterContext)
        {
            var action     = filterContext.RouteData.Values["action"] as string;
            var controller = filterContext.RouteData.Values["controller"] as string;

            return(ClaimsAuthorization.CheckAccess(action, controller));
        }
Esempio n. 2
0
        protected override bool AuthorizeCore(System.Web.HttpContextBase httpContext)
        {
            if (!string.IsNullOrWhiteSpace(_action))
            {
                return(ClaimsAuthorization.CheckAccess(_action, _resources));
            }
            var filterContext = httpContext.Items[_label] as AuthorizationContext;

            return(CheckAccess(filterContext));
        }