English 中文(简体)
由于许可不足,Cannot读组合文件
原标题:Cannot read configuration file due to insufficient permissions

我最近遇到了一个错误,试图把我的 as子网站同国际电算系统连接起来。 我找到了许多人穿戴的解决办法。

解决办法:

  1. Add IIS_IUSRS with Read permission on files in the folder
  2. Change IIS authentication method to BasicAuthentication
  3. refresh the website. It will work

(http://vivekthangaswamy.blogspot.com/2009/07/aspnet-website-cannot-read.html)

我在我的网站上增添了什么内容。 混淆文件。 我以前从未听过。 本文目前的内容是:

<?xml version="1.0"?>
<!--
  For more information on how to configure your ASP.NET application, please visit
  http://go.microsoft.com/fwlink/?LinkId=169433
  -->
<configuration>
    <connectionStrings>
  <add name="DefaultConnection" connectionString="Data Source=.SQLEXPRESS;AttachDbFilename=|DataDirectory|Database.mdf;Integrated Security=True;User Instance=True"
   providerName="System.Data.SqlClient" />
 </connectionStrings>
 <system.web>
  <compilation debug="true" strict="false" explicit="true" targetFramework="4.0"/>
    </system.web>
</configuration>

我的错误是:

Config Error: Cannot read configuration file due to insufficient permissions
Config File: ?C:Users*****DocumentsVisual Studio2010WebSitesPointsForTimeweb.config

最佳回答

网页无问题。 你们的网站正在进行之中。 您可以确定这一进程的身份。identity, 贵网站applicationgroup ,作为Network Services, Local System, 等,应获准上网和阅读。 config文档。

<><>Update:

www.un.org/Depts/DGACM/index_spanish.htm 这一更新的答复与上文相同,但更长、更简单、更完善。

www.un.org/Depts/DGACM/index_spanish.htm 首先,:你不必在座标上作任何改动。 <It s OK。 问题在于windows 文档许可

出现这些问题的原因是<>your application不能access/strong>和read web.config文档。

可查阅IIS_IUSRS。 Just right Point.config and Point properties, under security tab, AddIIS_IUSRS

因此,国际独立调查局——情报和安全局——什么?

www.un.org/Depts/DGACM/index_french.htm 如同任何外在文件一样,它应当由用户<>/strong>启动,并按照分配给该用户的<>/strong>许可运行

当网站IIS <>/strong>上启用时,Application Collective 链接到auser(Network Services, Local System, Etc.......)(可在 IIS中改动)。

因此,当你说IIS_IUSR时,这意味着: 任何用户<>>><>strong>(Network Services, Local System, Etc. ......)网站运行良好。

And as @Seph mentioned in comment below: If your computer is on a domain, remember that IIS_IUSRS group is a local group. Also make sure that when you re trying to find this user check the location it should be set to local computer and not a corporate domain.

问题回答

I had what appeared to be the same permissions issue on the web.config file.

However, my problem was caused by IIS failing to load the config file because it contained URL rewrite rules and I hadn t installed the IIS URL rewrite module on the new server.

解决办法是安装再版模块。

I had the same problem when I tried to share the site root folder with another user. Some folder lost the permission. So I followed the steps to add permission to IIS_IUSRS group as suggested by Afshin Gh. The problem is this group was not available for me. I am using windows 7.

What I did I just changed some steps:

  1. Right click on the parent folder (who lost the permission),
  2. Properties => Security =>In "Group or user names:",
  3. Click Edit...
  4. Window "Permission for your folder" will be opened.
  5. In "Group or user names:" press ADD... btn,
  6. Type Authen and press Check Names,
  7. You will see the complete group name "Authenticated Users"
  8. Press ok => apply.
  9. This should enable privileges again.

这为我工作。

Editor s note: Doing what this answer suggests: "changing Identity to LocalSystem" is DANGEROUS! The LocalSystem account is a ...

完全可靠的账户,多于管理账户。 单箱子上没有任何账户无法做到,它有权像机器一样进入网络(这要求积极目录,并允许机器账户允许某种)。


将身份从ApplicationPoolIdentity改为 localSystem是这项工作的;

I am using win7 64 with IIS 7.5

more about Application Pool Identity in IIS 7.5 and win 7

enter image description here

可查阅IIS_IUSRS。 请点击你的网络。 没收、扩大财产,并在安全表格下,添加IS_IUSRS。 将该团体改为/参加。

当该团体有<>NOT时,将IIS_IUSRS改为ComputerNameIIS_IUSR

你不必改变你们的网络。

问题是档案系统许可。 你的档案许可不允许国际独立调查局用户访问网络。 修改其窗户的档案许可,以便国际独立会计协会——情报和安全局账户能够查阅。

当你批准IIS_IUSR时,请在上查 缩略语

“entergraph

亲子、右翼和选择Properties。 选取 Security,贴上许可和。 页: 1 www.un.org/Depts/DGACM/index_french.htm 选择<>IIS_IUSRS,并点击OKOK。 检查<>。 页: 1

Job done!

出于某种原因,您的网络。 页: 1 Uncheck theread only Options of web.config file.

I needed to add permissions to IUSR (in addition to ISS-IUSRS, as others have suggested). (See also: http://codeasp.net/blogs/raghav_khunger/microsoft-net/2099/iis-7-5-windows-7-http-error-401-3-unauthorized)

你们不能接触所有用户,如IIS_IUSRS,也只能利用网站获得应用联营身份。 这是微软所建议的做法,在此可以找到更多的信息:

https://support.microsoft.com/en-za/help/4466942/understanding-identities-in-iis

https://learn.microsoft.com/en-us/iis/manage/configuring-security/application-pool-identities

Fix:

enter image description here

首先是研究上文的“Fig文档参数”,以确定需要查阅的地点。 在本案中,整个<编码>出版的复印机需要查阅。 右侧点击碎块和选择财产,然后用安全刀刺。

“enterography

www.un.org/Depts/DGACM/index_spanish.htm 页: 1

现在看因特网信息服务管理人员和应用程序库:

enter image description here

在我的情况下,我的网站由当地试验应用人才库管理,然后我进入<代码>。 缩略语

enter image description here

Press Check Names and the user should be found.

“entergraph

用户必须获得的接入(Default: Read & Execute, List rafter content and Read)和一切工作。

我利用次子制作从D:到C的地图:以便与团队中的其他开发者保持同样的设置。 这也给我留下了同样的错误。 取消这一规定给我。

IIS 申请Virtual Directory 载有前瞻性内容的《物理途径/,而不是斜.。 在我们的持续交付过程中,曾意外地利用国际船舶和船舶安全局的“动力管理工具”。

Bad Config Example - applicationHost.config

<application path="/MySite/MyService" applicationPool="MyAppPool" enabledProtocols="http">
    <virtualDirectory path="/" physicalPath="C:inetpubMySite/MyService" />
</application>

确保<代码>物理 途径属性不包含上下限(/,但只包含斜lash()。

Corrected Config Example - applicationHost.config

<application path="/MySite/MyService" applicationPool="MyAppPool" enabledProtocols="http">
    <virtualDirectory path="/" physicalPath="C:inetpubMySiteMyService" />
</application>

将程序模式识别改为当地系统,给我确定这一问题。 如果你正确点击申请库,选择“先进环境”,你就能够找到这一环境。 页: 1

Shift your project to some drive other than C: Worked for me with the same error.

公认的解决办法对我来说是没有的。 我用了一枚吉 Git,带上了以下双手:

c:usersmyusernamesource
eposmyWebSite

我制作了新的国际空间法研究所网站,并指出了这一网站。 哪些人没有在接受的解决办法中建议给予主人许可。 当我增加许可时,它依然没有工作。

只是在我向用户团体提供以下许可时,它才开始工作,而继承则附带了上网许可。 或许应该将其应用到网络上,以便减少攻击表面面积。

“User

All answers given are valid and working under different circumstances.

www.un.org/Depts/DGACM/index_spanish.htm 对我来说,重新启动视觉演播室工作。

We had a website running with a specific identity in the apppool, only after giving that user read access to the folder containing the web.config would it work. We tracked this down after adding the everyone user with read and everything worked fine.

对我来说,在我当地机器的缩编过程中出现错误,结果与基网有关。 在汇编网站时,网络框架。 My C:vilMicrosoft.NETFramework64v4.0.30319Configweb.config file with an uncognized content (组别级文献目录)。 由此确定出500.19个错误。

。 IIS 管理人员可浏览有关网络4“应用的数据。

右 click网点击。 Config => Tab Security => Button Edit => Button Add => Button Superior => Button Find Now = > Insearch results selected You group (in we case “IIS_IUSRS” => Ok => Ok=> Ok

I have solved this by adding read permission to folder for application pool user (WIN SERVER 2008 R2): C:WindowsSystem32inetsrvconfig

A little background: Our server has been hacked using classical error where app user had more permissions that it should (local admin).

为了确定它,我们创建了新的域名用户,这些用户只获得申请文件夹的许可,其中需要权利,并指定它为申请库用户。 这比我们对这个问题的打击大,是我们问题的解决。

如果你的申请是虚拟的目录,而查阅档案的道路是地图上的驱动力,就可以做到这一点。

如果你把档案改道到当地驾驶,如果这确实是你的问题,这将解决。

上述答复很有帮助,但如果是帮助任何人——我有这个具体问题,我发现我是(网络网点)分享网站的主人。 我们杀死了这一份额,并增加了用户的许可,使之读/出价,再一次做了罚款。

我怀疑这一份额。

我也收到“由于许可不足,没有读写文件”。 • 取消国际不动产业协会和农产企业对国际不动产业协会的限制。 NET 4.0 32bit和64bit被定为否认。 给他们打上标记,使我的问题固定下来。

Had this issue with a Virtual Application. All the permissions were set. IIS_IUSRS, AppPoolIdentity and then gave full access to Everyone. Nothing worked. Restarted apppool, site and IIS but No go.

Deleted the virtual application and added it again from scratch and it started working.

Wish I knew what solved it.

check if the file is not marked as read-only, despite of the IIS_IUSRS permission it will display the same message.

我有这一错误的信息,其原因是,我的体力被放在网络驱动力上,而不是在当地驾驶。 对这种驱动力的许可似乎有所不同。 例如,虽然当地驾驶地点允许当地计算机用户使用,但网络所在地没有。

此外,已接受的答案并不适用于这种情况。 当地用户或用户无法向用户分配许可。 解决办法是将体力推向地方驱动力。

I had the same issue and after doing all the stuff written here as answers, it still reproduced. The second half of the issue was the fact that .NET was turned off under "Turn Windows features on or off"

有时,如果是新的服务器,你需要配置或安装伙伴关系。 互联网网址上的网络特征是能够阅读你的网站。 config文档。

在我的案件中,这是原因。

In my case, I was trying to host pages from a mapped drive (subst). The issue is that the subst was run under my account and the IIS user is not able to see the same drive





相关问题
Anyone feel like passing it forward?

I m the only developer in my company, and am getting along well as an autodidact, but I know I m missing out on the education one gets from working with and having code reviewed by more senior devs. ...

How to Add script codes before the </body> tag ASP.NET

Heres the problem, In Masterpage, the google analytics code were pasted before the end of body tag. In ASPX page, I need to generate a script (google addItem tracker) using codebehind ClientScript ...

Transaction handling with TransactionScope

I am implementing Transaction using TransactionScope with the help this MSDN article http://msdn.microsoft.com/en-us/library/system.transactions.transactionscope.aspx I just want to confirm that is ...

System.Web.Mvc.Controller Initialize

i have the following base controller... public class BaseController : Controller { protected override void Initialize(System.Web.Routing.RequestContext requestContext) { if (...

Microsoft.Contracts namespace

For what it is necessary Microsoft.Contracts namespace in asp.net? I mean, in what cases I could write using Microsoft.Contracts;?

Separator line in ASP.NET

I d like to add a simple separator line in an aspx web form. Does anyone know how? It sounds easy enough, but still I can t manage to find how to do it.. 10x!