0

Do applications make use of different local ports for concurrent connections or is it the same port number that is being used for the second new connection? For example if i open My Firefox Browser (on port 57615) and i want to open another Firefox application (i.e. 2 concurrent applications running now). Will Both applications run on Port 57615 (example port) or will the second Firefox application be assigned a different local port (e.g 5766)?

(i.e I opened Firefox Application and I opened another Firefox Application)

Using the command below shows it's using the same port Number for both Concurrent Applications BUT I would Like to be VERY SURE!!!

netstat -ano |find / "firefox.exe"

netstat -ano |find / "process id"

Cheers

Community
  • 1
  • 1
Godwin
  • 3
  • 3
  • I am referring TO Ports on the Client side (i.e client machine, not Port 80 or 443) – Godwin Jan 21 '13 at 15:41
  • Port numbers must be unique. The client-side port number is dynamically established by the tcp/ip stack, just any number that is not in use. From the ephemeral port number range: http://en.wikipedia.org/wiki/Ephemeral_port – Hans Passant Jan 21 '13 at 15:47
  • @HansPassant, Thank you for your response. But based on what i saw using the netstat command, The Application (i.e Firefox still makes use of the same Port Number after i opened another Firefox application) – Godwin Jan 21 '13 at 15:53
  • @Hans Passant, Imagine opening Firefox (check port Number) and Opening ANOTHER Firefox Application (and checking the port Number)...I think its making use of the same Port Number..but need to be sure am on the right track before proceeding – Godwin Jan 21 '13 at 15:55

1 Answers1

2

Firefox doesn't use one port, it's a client application so every time it initiates a connection it asks for it to the Operating System, the latter assings a different port number for every connection.

So, it doesn't matter how many Firefoxs you opened but how many connections each Firefox initiated, each connection will have a different local port.

Perhaps you get the same port every time you use Firefox because it is returning the resources to the operating system when you close it and the new execution it's getting the same port.

pmoleri
  • 4,238
  • 1
  • 15
  • 25
  • Thank you for your response, Really appreciate. I now clearly and fully understand. i also used CurrPorts - a free utility to see this. http://www.nirsoft.net/utils/cports.html – Godwin Jan 21 '13 at 17:06