I have a problem.

Program X connects to a server on port 5555.
While program X is working, the server will be sending information to program X every 10-20 seconds.

I want to tap into that connection and display information that was sent from the server to program X in my program.

I don't have to intercept and block the information, just copy the information into my program. Sniffing is I believe the correct terminology.

I tried to create a winsock TCP connection on port 5555 but I am not sure if I'm doing it correctly. Thanks.