Home » IIS » How to run a Visual Studio project on Local IIS without Administrator rights

How to run a Visual Studio project on Local IIS without Administrator rights

Due to the company policies, many developers don’t have Administrator rights on the machines they use for development. Microsoft released IIS Express to allow these developers load and run projects in Visual Studio without Administrator rights.

If your project is somehow not compatible with IIS Express and you want to run it on Local IIS without Administrator rights on the machine, try the two workarounds below. They are not guaranteed to work but you may save a lot of time if they do work.

Run your .NET project on Local IIS without Administrator rights

There are two workarounds worth trying:

  • Run the application pool under the non-admin user’s account
  • Give SeDebugPrivilige to the domain user account

Run the application pool under the non-admin user’s account

  1. Search for Internet Information Services in Start
  2. Go to Application Pools. Select DefaultAppPool
  3. Go to Advanced Settings on the right side
  4. Change Identity to your domain user account
  5. Reset IIS (Go to Command Prompt and run iisreset)
  6. Test running the VS project in Local IIS (without admin rights)
  7. If it doesn’t work, try the second suggestion below (SeDebugPrivilege)
Run your .NET project on Local IIS without Administrator rights

If this works and you want to use this workaround, please consider the risk below.

Before you change the ASP.NET worker process to run under a different account, consider the possible consequences if the ASP.NET worker process should be hacked while running under that account. The ASPNET and NETWORK SERVICE user accounts run with minimal permissions, reducing the possible damage if the process is hacked. If you must change the ASP.NET worker process to run under an account that has greater permissions, the potential damage is greater.

Source

Give SeDebugPrivilige to the domain user account

  1. Search for “run” in Start
  2. Type gpedit.msc
  3. Navigate to “Local Computer Policy > Computer Configuration > Windows Settings > Security Settings > Local Policies > User Right Assignment > Debug programs
  4. Add user’s account
  5. Restart the machine
  6. Test running the VS project in Local IIS (without admin rights)

If this works and you want to use this workaround, please note that the user who has given Debugging permission can debug all services in Windows.

If you want to manage IIS locally but you don’t have Administrator permissions, check this post out for the solution: How to manage IIS locally with a non-admin account?

Ned Sahin

Blogger for 20 years. Former Microsoft Engineer. Author of six books. I love creating helpful content and sharing with the world. Reach me out for any questions or feedback.
Categories IIS

Leave a Comment