【问题标题】:I am getting the following error while running the same application on a different machine在另一台机器上运行相同的应用程序时出现以下错误
【发布时间】:2021-08-20 03:52:46
【问题描述】:

配置错误 此配置部分不能用于此路径。当该部分锁定在父级别时会发生这种情况。锁定是默认情况下 (overrideModeDefault="Deny") 或由具有 overrideMode="Deny" 或旧 allowOverride="false" 的位置标记显式设置的。 配置文件\?\C:\GitSrsCodes\IMS\IMS.Web\web.config。我还附上了一张图片:enter image description here

任何帮助和建议都会非常有帮助 - 谢谢

【问题讨论】:

标签: asp.net asp.net-mvc web-config


【解决方案1】:

以下方法帮助我解决了上述问题: 寻找以下几行

<section name="windowsAuthentication" overrideModeDefault="Deny" />
<section name="anonymousAuthentication" overrideModeDefault="Deny" />
<add name="WindowsAuthenticationModule" lockItem="true" />
<add name="AnonymousAuthenticationModule" lockItem="true" />
Change those lines to

<section name="windowsAuthentication" overrideModeDefault="Allow" />
<section name="anonymousAuthentication" overrideModeDefault="Allow" />
<add name="WindowsAuthenticationModule" lockItem="false" />
<add name="AnonymousAuthenticationModule" lockItem="false" />

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2015-09-08
    • 2018-09-18
    • 2019-10-26
    • 1970-01-01
    • 2018-04-21
    • 1970-01-01
    • 2011-11-19
    • 2020-06-04
    相关资源
    最近更新 更多