24

We are working on vs 2010 windows 7, 32 bit and the project is running under target framework 3.5.

Now we are implementing credit card process in the website project in signup page.

It's running fine when running from VS IDE, but after publishing to the local IIS when clicked on signup button, it's showing this error:

An unhandled win32 exception occured in w3wp.exe The Just-In-Time debugger was launched without necessary security permissions. To debug this proces, the JIT debugger must be run as an administrator. Would you like to debug the proces?

In Application error log im seeing this

Faulting application name: w3wp.exe, version: 7.5.7600.16385, time stamp: 0x4a5bcd2b
Faulting module name: ntdll.dll, version: 6.1.7600.16385, time stamp: 0x4a5bdadb
Exception code: 0xc0000374
Fault offset: 0x000c283b
Faulting process id: 0x3e4
Faulting application start time: 0x01cca60dbfd76d52
Faulting application path: c:\windows\system32\inetsrv\w3wp.exe
Faulting module path: C:\Windows\SYSTEM32\ntdll.dll
Report Id: 126cc4b9-1201-11e1-b3db-003018a9eb5e

It was working fine three days ago from IIS. I do not understand what change caused this issue.

Edited

if i select debug this process.. app working fine. The real problem is after publishing same build to the live server(win 2k8, 64 bit), in sign up page i used captcha even i entered correct code its saying you are not entered correct code. which is working fine in local system.

praveenb
  • 10,549
  • 14
  • 61
  • 83

7 Answers7

35

I don't know if your problem had the same cause, but I got this error when trying to debug my app (just pressing F5).

We got crazy trying to figure why the w3wp.exe was failing with this error when minutes before it was running fine.

After some investigation we realized that the real problem was in the code of the global.asax: it was throwing an stack overflow exception (pretty ironic for answering here) and that was crashing the w3wp.exe process before VS could attach it to begin debug.

Fixing the buggy code made the VS to run nicely again.

I see the question is from long ago, but I hope it helps somebody.

Cory House
  • 14,235
  • 13
  • 70
  • 87
mapache
  • 1,361
  • 9
  • 11
  • 1
    Thanks mapache, I just had the same issue and was solved by selecting attach to the process and fixing the stack overflow exception bug. – wacdany Sep 19 '13 at 06:32
  • 4
    same here (code error): in my case I had a "Html.Partial" calling itself inside an MVC view, causing some overflow or something. – Carlos R Balebona Apr 03 '15 at 03:29
  • 6
    `Debugger.Break()` in global.ascx cause same problem! – alsafoo Apr 13 '15 at 20:31
  • 1
    Thanks, In my case the code to set relationship between layout page and my content page was incorrect. when I commented that code the error popup was gone. – Beginner Jun 17 '16 at 14:29
  • 1
    In my case that was StackOverflowException caused by circular reference in Unity Container. Initially I was debugging using Local IIS, and I got error described in the question title. However, after I switched to IISExpress I got actual exception inside my code. – Illidan Jun 23 '17 at 04:39
  • Try browsing through IIS and see if website loads properly. A simple config error in web.config might cause this kind of issue as well. – Viku Jun 01 '20 at 09:54
1

I believe an update to the latest version of VS and .NET Core 2.1 is what caused this for me.

Then for the first time, I noticed this setting. Setting it to 'Enabled' fixed it for me. enter image description here

IQtheMC
  • 221
  • 3
  • 12
1

To solve this issue, let the dialog help you. Agree to launch an elevated debugger and debug your problem. You probably have some sort of configuration problem. Your real problem isn't whether or not the debugger is elevated, it's the fact you need a debugger at all. In other words the first sentence on the dialog is "you have a problem." All the other sentences are "I would like to help you with that problem; is that cool with you?"

Kate Gregory
  • 18,808
  • 8
  • 56
  • 85
0

If you usually attach to process and debug but you can't (because you can't get the app to successfully run), run the app via Visual Studio and it'll break and show you the exception cause in some detail.

Chris Halcrow
  • 28,994
  • 18
  • 176
  • 206
0

Please check for System.Diagnostics.Debugger.Launch(); or Debugger.Launch(); in the cs file. Commenting the code, starting the application worked fine for me.!

TechDo
  • 18,398
  • 3
  • 51
  • 64
0

I was experiencing this error because of the AppPool that was associated with my site. Originally, I was using DefaultAppPool. The fix was to use a different app pool (custom, from our app) that had NetworkService as the identity.

Ryan Rodemoyer
  • 5,548
  • 12
  • 44
  • 54
0

In my case it was stackoverflow due to circular dependency injection

public class ServiceA : IServiceA
{
   public ServiceA(IServiceB serviceB){...}
}

public class ServiceB : IServiceB
{
   public ServiceB(IServiceA serviceA){...}
}
mtareq
  • 171
  • 2
  • 4