it:ad:iis:issues:500.19_section_is_locked_at_a_parent_level

IT:AD:Infrastructure:IIS:Issues:500.19:Section is Locked at a Parent Level

Summary

Installed a new site.

Getting an error message about:

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". 
   

And below that:

<windowsAuthentication enabled="true" useKernelMode="true" useAppPoolCredentials="true">

The parent applicationHost.config element is locking it down.

Need to use one or both of the following commands to edit the applicationHost.config file located within C:\Windows\System32\inetsrv\config (changing the name of the website of course):

C:\Windows\System32\inetsrv\appcmd.exe unlock config "Default Web Site" /section:anonymousAuthentication -commit:apphost

C:\Windows\System32\inetsrv\appcmd.exe unlock config "Default Web Site" /section:windowsAuthentication -commit:apphost

this generates something like below in Windows 7:

<location path="Default Web Site" overrideMode="Allow">
    <system.webServer>
        <security>
            <authentication>
                <anonymousAuthentication />
                <windowsAuthentication>
                    <providers />
                    <extendedProtection />
                </windowsAuthentication>
            </authentication>
        </security>
    </system.webServer>
</location>
  • /home/skysigal/public_html/data/pages/it/ad/iis/issues/500.19_section_is_locked_at_a_parent_level.txt
  • Last modified: 2023/11/04 01:45
  • by 127.0.0.1