On Friday I gave a demo of an MVC application using the Authorize attribute on my JobCardController, and all was well. This morning, when I attempt an unauthorized action, I still get redirected to the LogOn view, using the below URL, but I appear to have what my reading tells me is called a White Screen of Death, i.e. nothing but white background and no actions invoked.
http://localhost:34054/Account/LogOn?ReturnUrl=%2fJobCard
ADDENDUM:
I forgot to mention that I have moved the Account models and services out into my DataObjects and Services projects, but I had done this last week already without this problem.
I’m not asking what is wrong, but what are the common faults that could cause something like this and how can I start debugging this mess?
SOLVED:
Somehow an Authorize attribute had landed up on my whole controller class, as in,
[HandleError]
[Authorize]
public class AccountController : BaseController
I removed that and everything is working again.
Somehow an Authorize attribute had landed up on my whole AccountController class, as in,
So, the controller was being repeatedly hit by an unauthenticated user for the same action invocation. I’m surprised this didn’t cause some sort of ‘stack overflow’ condition.