I'm trying to set up remote debugging for a VirtualBox VM running XP SP3, following this tutorial.

On the guest OS I've started the remote debugging server:

enter image description here

I have verified that I can connect to the server using netcat:

C:\Users\sashoalm>ncat.exe myorgani-1bd08e 4015
Hello?
W Çclose: No error

But when I try to connect from the Debug->Attach to Process... dialog (I put myorgani-1bd08e for the Qualifier), I get this error:

Unable to connect to 'myorgani-1bd08e'. An attempt was made to access a socket in a way forbidden by its access permissions.

The MSDN docs about this error say this:

WSAEACCES 10013 Permission denied. An attempt was made to access a socket in a way forbidden by its access permissions. An example is using a broadcast address for sendto without broadcast permission being set using setsockopt(SO_BROADCAST). Another possible reason for the WSAEACCES error is that when the bind function is called (on Windows NT 4.0 with SP4 and later), another application, service, or kernel mode driver is bound to the same address with exclusive access. Such exclusive access is a new feature of Windows NT 4.0 with SP4 and later, and is implemented by using the SO_EXCLUSIVEADDRUSE option.

Why do I get this error?

有帮助吗?

解决方案

In the end, it turned out to be the firewall on my own computer that was preventing Visual Studio from making outbound connections (there was an outbound rule for devenv.exe, and I have no idea how it got there).

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top