asp.net-mvc – 所有请求获取HTTP错误401.2 – 未经授权的响应
发布时间:2021-01-17 14:24:16 所属栏目: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 – 如何MSDeploy构建的网站包到一个处女IIS网站
- asp.net-mvc – 如何将ASP.Net MVC路径段中的1或0映射到布尔
- asp.net-mvc-3 – 如何在页面提交ASP.Net MVC时捕获哪个单选
- asp.net后台cs中的JSON格式变量在前台Js中调用方法(前后台示
- asp-classic – 经典的asp / asp.net网站 – global.asa无效
- asp.net-mvc – 在EditorFor for child对象中使用时,MVC无法
- ASP.NET Web应用程序本地化的最佳实践
- asp.net操作xml增删改示例分享
- asp.net-mvc-4 – MVC4捆绑GZIP和头文件
- ASP.net MVC ValidationSummary总是被渲染
推荐文章
站长推荐
- asp.net – LINQ:不支持查询运算符’ElementAtO
- asp.net-mvc – 应用程序服务层作为静态类
- asp.net-mvc – 删除布局将默认为_ViewStart,为什
- asp-classic – 哪里可以存储经典ASP的连接字符串
- asp.net-mvc-4 – MVC 4 DropDownListFor错误 –
- asp.net-mvc – 防止在ASP.NET MVC中缓存属性,每
- ASP.NET Core使用SkiaSharp实现验证码的示例代码
- asp.net-mvc-3 – ASP.Net MVC 3:在哪里处理会话
- ASP.NET TextBox LostFocus事件
- asp.net-mvc – KendoUI网格显示总记录数
热点阅读
