title: MVC 4 website with .NET 4.5 on IIS 8 in Windows 8 gives 403.14 forbidden error
body: <p>I have a website that I built in Visual Studio 2012 using MVC 4 and .NET framework 4.5.  When I try to run it via IIS 8 on a machine running Windows 8 Pro, I get a 403.14 Error.  It says </p>
  
  <p>"Forbidden
  The Web server is configured to not list the contents of this directory.</p>
  
  <p>Most likely causes:
  A default document is not configured for the requested URL, and directory browsing is not enabled on the server."</p>
  
  <p>Here are some things I have tried that did not work:</p>
  
  <ul>
  <li>Run %windir%\Microsoft.NET\Framework\v4.0.30319\aspnet_regiis.exe <strong>-i</strong> and 
  %windir%\Microsoft.NET\Framework\v4.0.30319\aspnet_regiis.exe <strong>-ir</strong> in both this and the Framework64 directory.  This gives this error: "This option is not supported on this version of the operating system.  Administrators should instead install/uninstall ASP.NET 4.5 with IIS8 using the "Turn Windows Features On/Off" dialog,  the Server Manager management tool, or the dism.exe command line tool.  For more details please see <a href="http://go.microsoft.com/fwlink/?LinkID=216771" rel="noreferrer">http://go.microsoft.com/fwlink/?LinkID=216771</a>."  The link goes to a page about Windows Server 2012 which does not help.  I could not find a specific setting in "Turn Windows Features on or off" dialog for iis 8.  Everything relating to .net 4.5 is turned on.</li>
  <li>Add  to  in Web.config. This gives the error: "This configuration section cannot be used at this path. This happens when the section is locked at a parent level. Locking is either by default (overrideModeDefault="Deny"), or set explicitly by a location tag with overrideMode="Deny" or the legacy allowOverride="false"."</li>
  </ul>
  
  <p>I have made sure .net 4.5 is installed on the server (the installer said it is built into windows 8 and does not need to be installed).  The application pool is the default pool using .net 4.0, integrated pipeline, with 32 bit applications enabled.  I'm publishing to the default directory (inetpub\wwwroot) and the default site that was there worked fine.  HTTP Redirection is turned on in "Turn windows features on or off"</p>
  
  <p>Can anyone offer any more insights?</p>
  
  <p>EDIT:
  Well, of course right after I post this I found something that works. Go figure.</p>
  
  <p>In "Turn Windows Features on or off", under Internet Information Services -> World Wide Web Services -> Application Development Features, make sure that .NET Extensibility 3.5, .NET Extesibility 4.5, ASP.NET 3.5, ASP.NET 4.5, ISAPI Extensions, and ISAPI Filters are SELECTED.</p>
  
  <p>This was outlined here: <a href="http://www.iis.net/learn/get-started/whats-new-in-iis-8/iis-80-using-aspnet-35-and-aspnet-45#TOC301258515" rel="noreferrer">http://www.iis.net/learn/get-started/whats-new-in-iis-8/iis-80-using-aspnet-35-and-aspnet-45#TOC301258515</a> but since that refered to server 2012 instead of windows 8 I couldn't find the right location for these settings.</p>
  
  <p>Hope this helps anyone with a similar problem. Thanks for reading.</p>