This small blogpost contains information on how to disable the security warnings when debugging within Visual Studio.
When you are debugging your web projects in Visual Studio and you are running your websites on IIS, you could get a security warning like this:
This happens when you are attaching your debugger to the w3wp.exe process.
MSDN says the following about the reason this box appears:
"This warning dialog box appears when you attach to a process that contains partially trusted code or is owned by an untrusted user immediately before the attach occurs. An untrusted process that contains malicious code has the potential to damage the computer doing the debugging. If you have reason to distrust the process, then you should click Cancel to prevent debugging."
So of course you should NOT continue reading if you need to have any kind of influence on this process.
To disable these warnings for Visual Studio you should make a change in the registry.
Change registry settings
IMPORTANT: make sure that Visual Studio is not running when making the changes to the registry key or it will be overwritten with the old value on exit.
Change the registry value to ‘1’ for the following keys, depending on your version of Visual Studio.
Visual Studio 2008
Visual Studio 2010
Visual Studio 2012
Visual Studio 2013
Visual Studio 2015
For VS2015, you need to create the Registry Key referenced above.
- Make sure Visual Studio is not running, and open the Registry Editor.
- Navigate to HKEY_CURRENT_USER\Software\Microsoft\VisualStudio\14.0\Debugger, right-click and create a new DWORD:
- Name: DisableAttachSecurityWarning
- Value: 1.
To make things a bit more easy, you can download a .gist, which you can merge with your registry: