Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Debugging Dot Net Website as Domain Normal User

We are developing asp.net website, API and MVC project using Visual Studio. Currently the system we're using are using local administrator account. We are now mapping it to the domain user (normal user). However, certain features are not supported by Visual Studio when we do things like this... importantly..

  • Debugging applications that a run under a different user account, such as ASP.NET websites.
  • Deploying a web application to Internet Information Services (IIS) on a local computer.

Check MSDN Doc here

Note that deploying to IIS is not an issue for us, however the we're unable to debug the application and that is real deal breaker here!

I would like to know how to do debugging for asp.net websites when using domain mapped normal user.

I know this is not a programming related question. However, seems like most of dot net programmers are affected with this and I don't know where to ask for help, so posting it here. (Suggest if any other site is suitable for this!)

Thank you for your help in advance.

like image 897
Krunal Avatar asked Oct 17 '22 21:10

Krunal


1 Answers

The simple answer, as mentioned in that MSDN document and this SO question, is that you can't.

It might be possible to do it through roundabout ways, such as changing the credentials that the IIS worker, application pool, and related processes run as, but even if it were possible, it wouldn't be supported, and most likely wouldn't be worth the effort. Here are two very old articles that deal with the topic:

  1. https://msdn.microsoft.com/en-us/library/aa289173(VS.71).aspx
  2. http://jameskovacs.com/2006/03/16/debugging-as-a-nonadmin/

It may be more feasible if you're able to run your application in an OWIN (Wikipedia) container running in an alternate (to IIS) host.

like image 185
John K Avatar answered Oct 20 '22 23:10

John K