101 · Question #638
A client's operating system needs to make sure that data received from a server is mapped to the application that requested it. How does it complete this mapping?
The correct answer is B. using the client source port. The client OS uses the client-side source port number to demultiplex incoming server responses to the correct local application or socket.
Question
A client's operating system needs to make sure that data received from a server is mapped to the application that requested it. How does it complete this mapping?
Options
- Ausing the TCP sequence number
- Busing the client source port
- Cusing the TCP acknowledgement number
- Dusing the server source port
How the community answered
(49 responses)- A2% (1)
- B92% (45)
- C4% (2)
- D2% (1)
Why each option
The client OS uses the client-side source port number to demultiplex incoming server responses to the correct local application or socket.
TCP sequence numbers are used to order and reassemble out-of-order segments, not to identify which local application should receive the data.
When a client application opens a connection, the OS assigns an ephemeral source port that uniquely identifies the socket for that specific application. When the server's response arrives, the destination port in the incoming TCP segment matches the original client source port, allowing the OS to route the data to the correct waiting process. This port-based multiplexing is fundamental to how TCP/IP supports multiple simultaneous application connections on a single host.
TCP acknowledgement numbers indicate the next expected byte from the sender and are used for reliable delivery confirmation, not for application-level demultiplexing.
The server source port identifies the service on the server side (e.g., port 80 for HTTP) and is the same for all clients, so it cannot uniquely identify a specific client application.
Concept tested: TCP/IP port-based application demultiplexing
Source: https://www.rfc-editor.org/rfc/rfc793
Topics
Community Discussion
No community discussion yet for this question.