troubleshooting Question

Socket connection actively refused

Avatar of josgood
josgoodFlag for United States of America asked on
C#
3 Comments1 Solution1489 ViewsLast Modified:
I'm new to socket programming.  I have
         Socket socket = new Socket(AddressFamily.InterNetwork,SocketType.Stream,ProtocolType.Tcp);
         IPHostEntry host = Dns.GetHostEntry("localhost");
         IPEndPoint endPoint = new IPEndPoint(host.AddressList[0],8080);
         socket.Connect(endPoint);
The Connect call fails with "No connection could be made because the target machine actively refused it".

The debugger says host.AddressList[0] is 127.0.0.1.

I'm running Windows XP Media Center Edition Version 2002 SP2.  I have ZoneAlarm installed, with trusted zone security turned off.  I have the same problem if I shut it down.  Windows Firewall is turned off.

I probably need to turn off some protection or enable port 8080 somewhere, but I don't know where to look.

I appreciate your help.
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 3 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 3 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros