title: ASP.NET MVC - Easy way to temporarily require authorisation for whole site except one page
body: <p>I am building a site with a mixture of public and member-only pages.  The login system works fine as it is.</p>
  
  <p>However I'd like to launch a closed, invite-only preview and temporarily require visitors log in for all actions except the welcome page.</p>
  
  <p>Currently I have <code>[Authorize]</code> attributes on certain action methods.  I could add additional attributes to the other action methods too, but this feels a bit hacky and will make it harder to remove them correctly later when I want to revert to having more open content.</p>
  
  <p>So, how can I effectively add a site-wide authorisation requirement?  Recall that I want the single <code>/Home/Index</code> route to remain public as well, so that people I've invited can read some information before activating their invites.</p>