views:

121

answers:

1

When the webbrowser control issues an HTTP request to a URL, it is assigned a port - which is utilized for the length of that connection.

Is there away to find out which port is being utilized for each connection the webbrowser control establishes/issues?

A: 

Every request is potentially using a different port. Since most requests are resolved in a couple of seconds and then closed, having the port information on the client isn't going to be very helpful.

If you're interested from a historical perspective, you can add the port number to the logs that many web servers generate.

In order to view this information live you can use a tool such as TCPView

Now for the real question. What are you trying to do? There may be an easier way.

Brad Bruce
I am trying to get a historical view from the client perspective, not the server one.TCPView could help, but the problem is that I need to build it in my application, not sure that is open source...
Hmmm. Interesting! I can imagine a few places where that kind of information might be useful. (Ammunition for when the network wonks mess up the firewall rules <G>) The netstat command would probably be a better place to start than TCPView in this case. I ran across this article that might be interesting http://poshcode.org/558
Brad Bruce

related questions