Take the 2-minute tour ×
Software Quality Assurance & Testing Stack Exchange is a question and answer site for software quality control experts, automation engineers, and software testers. It's 100% free, no registration required.

On a Windows 7 amd4 box, I have an application that creates a TCP socket.

My aim is to check whether this is a dual-stack socket. (Dual-stack sockets are available in Windows since Vista.)

For example, when running NetBeans, I can see this socket in in netstat and Process Explorer:

TCP    [::1]:49851            [::]:0                 LISTENING

But this one behaves as TCPv6--even when it's listening, is closed. But I'm not sure if I understood the feature right, so it might be invalid assumption.

How do I obtain as much information as I can about sockets?

share|improve this question
Have you tried this from the article you linked: "One method that can be used to detect if IPv4 is enabled or disabled is to call the socket function with the af parameter set to AF_INET to try and create an IPv4 socket. If the socket function fails and WSAGetLastError returns an error of WSAEAFNOSUPPORT, then it means IPv4 is not enabled." –  Sam Woods Jul 26 '12 at 18:59
@SamWoods I'm not trying to check if IPv4 is enabled on the system (which is what I believe the text you cited is talking about). I'm trying to obtain information about existing socket from outside of the application –  Alois Mahdal Jul 27 '12 at 6:55
You're question is much technical so you may find more support by asking it at more technical sites of stackexchange, e.g. superuser.com, serverfault.com, stackoverflow.com –  dzieciou Jul 28 '12 at 7:35
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.