how socket communication happens on same port?

From: rahul8143 (rahul8143_at_gmail.com)
Date: 03/31/05


Date: 31 Mar 2005 03:40:38 -0800

Hello all,
     If i run tcpserver on pc1 with port 9200 ,tcpclient on pc2 with
9200 and same in reverse tcpclient on pc1 ,tcpserver on pc2 on 9200.
How can both programs work on same port without problem?
    why it not require to have different port to read/write to sockets
from pc1 to pc2 and pc2 to pc1?
regards,
rahul.



Relevant Pages

  • Re: network programming: how does s.accept() work?
    ... The program you contact at Google is a server. ... so, the server will usually assign a new port, say 56399, specifically ... connections to a server remain on the same port, ... sockets is what identifies them. ...
    (comp.lang.python)
  • Re: Socket switch delay
    ... hadn't realized the bit about the completion port... ... > can come back with partial buffers from a completion io. ... > in the client and server. ... > remember changing in the server was the "non-blocking sockets" together ...
    (microsoft.public.win32.programmer.networks)
  • Re: security risk of having a long list of services in inetd
    ... for connections on certain internet sockets. ... the string 'ssh' means TCP port 22. ... But if there's no program sitting there listening on the port there's ...
    (Debian-User)
  • Re: Router/Firewall Port Mapping Question
    ... Sockets on the PC can be client or servers. ... The port number is usually selected by the ... and a Server on the other. ...
    (comp.security.firewalls)
  • Re: Maximum sockets
    ... "Phil Frisbie, Jr." ... > you call connectWindows assigns it to a unused port. ... > connect and close less than 3976 sockets every two minutes. ... I thought the WSAEADDRINUSE error occurred only when a connection was ...
    (microsoft.public.win32.programmer.networks)