How to analyze file access rights issues in IIS?

322 Views Asked by At

I am trying to set up a web application to work in IIS. Among other things, I have created an "application" node pointing to my directory with binaries. That application node uses pass-through-authentication, and it uses an AppPool for which my current user is set as the identity.

For some reason, IIS thinks it cannot access those files, as evidenced by the "Test Connection" output:

authentication failure

The user name + password combination is definitely correct, as IIS checks the validity of the credentials already upon input.

Note that this is by far not the first time this is happening: I have set up this web application on many, many machines already over the past five years, and yet, every single time a new developer joins the team, or we have to set up a new machine, we keep struggling with these access rights issues for multiple hours, or even days.

In the end (just like I have started in this case), all kinds of users (<machine name>\User, <machine name>\Benutzer, "Everyone", authenticated users, administrators, anonymous user, IIS_IUSRS, ...) have been granted full access to all files on the disk. Usually, at some point (after so much trying, configuring, switching forth and back, that no-one knows what actually solved the issue), the problem is gone.

What is a more systematic and minimal approach to troubleshooting (or, better yet, avoid) this issue when setting up a web application in IIS?

1

There are 1 best solutions below

0
Qiang Fu On

For file access issues, use Process Monitor will be fine. Set the filter as "Process Name is w3wp.exe" "Result is not SUCCESS"

Add "user" column. Then you can check at which step, user access files unsuccessfully.

enter image description here