Ejemplo n.º 1
0
        protected override bool AuthorizeCore(HttpContextBase httpContext)
        {
            if (!_authorize)
            {
                return(true);
            }

            try
            {
                bool basicAuthed = base.AuthorizeCore(httpContext);
                if (basicAuthed)
                {
                    if (DomainAuthHelper.IsUserContextDomainAuthorized(httpContext))
                    {
                        return(DomainAuthHelper.UserHasSiteAccess(httpContext));
                    }
                }
            }
            catch (Exception e)
            {
                return(false);
            }
            return(false);
        }