asp.net-mvc – 所有请求获取HTTP错误401.2 – 未经授权的响应
发布时间:2021-01-17 16:36:30 所属栏目:asp.Net 来源:互联网
导读:我的MVC应用程序,直到几分钟前,一直工作正常(作为解决方案的一部分,作为asp / net成员).但是,无需明知地更改任何与每个请求相关的任何内容,甚至不需要任何授权属性等等. 我已经把所有的条目从web.config中取出,现在与授权有关,我已经检查了applicationhost.co
|
我的MVC应用程序,直到几分钟前,一直工作正常(作为解决方案的一部分,作为asp / net成员).但是,无需明知地更改任何与每个请求相关的任何内容,甚至不需要任何授权属性等等. 我已经把所有的条目从web.config中取出,现在与授权有关,我已经检查了applicationhost.config,它具有以下内容: <access sslFlags="None" />
<applicationDependencies>
<application name="Active Server Pages" groupId="ASP" />
</applicationDependencies>
<authentication>
<anonymousAuthentication enabled="true" userName="" />
<basicAuthentication enabled="false" />
<clientCertificateMappingAuthentication enabled="false" />
<digestAuthentication enabled="false" />
<iisClientCertificateMappingAuthentication enabled="false">
</iisClientCertificateMappingAuthentication>
<windowsAuthentication enabled="false">
<providers>
<add value="Negotiate" />
<add value="NTLM" />
</providers>
</windowsAuthentication>
</authentication>
<authorization>
<add accessType="Allow" users="*" />
</authorization>
任何人都可以建议可能导致这种情况吗? 谢谢 关于这一点的更多信息,我切换到使用完整的IIS,它的工作正常,所以它看起来像一个IIS Express问题.任何关于事业的线索?是否没有完整的IIS express gui除了系统托盘图标? 解决方法选项1:在applicationhost.config中检查是否有任何条目,如下所示.如果有任何这样的条目将anonymousAuthetication启用值从“false”更改为“true”. <location path="YOUR-APPLICATION-NAME">
<system.webServer>
<security>
<authentication>
<anonymousAuthentication enabled="false" />
</authentication>
</security>
</system.webServer>
</location>
选项2: 如果您正在使用visual studio,请确保已启用anonymousAuthentication. (编辑:日照站长网) 【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容! |
推荐文章
站长推荐
- asp.net-mvc – MVC应用程序调试错误:viewstate
- js触发asp.net的Button的Onclick事件应用
- asp.net-mvc-2 – 带有数组/列表的ASP.NET MVC 2
- asp.net-mvc-3 – MVC3非顺序索引和DefaultModel
- 修改服务器配置 让asp.net文件后缀名随心所欲
- asp.net-mvc – ie9:调试时出现恼人的弹出:“错
- asp.net – 在Web.config帮助中定义tagPrefixes
- 我是否需要在asp.net中取消订阅(手动订阅)活动?
- 我如何让Fiddler捕获我的MVC应用程序向我的ASP.N
- asp.net-mvc – asp.net mvc – string或int的路
热点阅读
