Sockets come in two primary flavors. An active socket is connected to a remote active socket via an open data connection... A passive socket is not connected, but rather awaits an incoming connection, which will spawn a new active socket once a connection is established ...
Each port can have a single passive socket binded to it, awaiting incoming connections, and multiple active sockets, each corresponding to an open connection on the port. It's as if the factory worker is waiting for new messages to arrive (he represents the passive socket), and when one message arrives from a new sender, he initiates a correspondence (a connection) with them by delegating someone else (an active socket) to actually read the packet and respond back to the sender if necessary. This permits the factory worker to be free to receive new packets. ...
Chat with our AI personalities