wwwroot permission setting

NET_EXPLORER 1 Reputation point
2021-06-23T05:59:01.297+00:00

I had a requirement to restrict access to people from reading the web.config file in wwwroot folder of inetpub.

All I did was removing the MACHINENAME/USERS Group from the permission settings of wwwroot folder.

Result: My site was getting access denied error.

I want to restrict the general users who login to the machine from reading the wwwroot contents. How do I achieve it. ? My app runs under DefaultAppPool Indentity.

Will giving access to IIS AppPool\<myappoolname> will work ?

Internet Information Services
ASP.NET Core
ASP.NET Core
A set of technologies in the .NET Framework for building web applications and XML web services.
4,118 questions
ASP.NET
ASP.NET
A set of technologies in the .NET Framework for building web applications and XML web services.
3,234 questions
{count} votes