Question

In: Computer Science

Hosts A and B are communicating over a TCP connection, and Host B has already received...

Hosts A and B are communicating over a TCP connection, and Host B has already received from A all bytes up through byte 126. Suppose Host A then sends two segments to Host B back-to-back. The first and second segments contain 80 and 40 bytes of data, respectively. In the first segment, the sequence number is 127, the source port number is 302, and the destination port number is 80. Host B sends an acknowledgment whenever it receives a segment from Host A.

(a) In the second segment sent from Host A to B, what are the sequence number, source port number, and destination port number?

(b) If the first segment arrives before the second segment, in the acknowledgment of the first arriving segment, what is the acknowledgment number, the source port number, and the destination port number?

Solutions

Expert Solution

Solution:

Given,

=>First segment: size = 80 bytes, sequence number = 127, source port number = 302, destination port number = 80.

=>Second segment: size = 40 bytes

(a)

Explanation:

Calculating second segment sequence number:

=>First segment's last byte sequence number = 127 + 80 - 1

=>First segment's last byte sequence number = 206

=>Second segment's sequence number = 206 + 1

=>Second segment's sequence number = 207

=>Source and destination port number will be same as the first segment number.

=>Hence source port number = 302, destination port number = 80.

(b)

Explanation:

Calculating acknowledgment number of first segment:

=>Acknowledgement number is 1 more than the sequence number of last byte received.

=>Acknowledgement number = 206 + 1

=>Acknowledgement number = 207

=>Now in acknowledgment source will be host B and destination will be host A hence source port number = 80, destination port number = 302.

I have explained each and every part with the help of statements attached to it.


Related Solutions

Hosts A and B are communicating over a TCP connection and Host B has already received...
Hosts A and B are communicating over a TCP connection and Host B has already received from A all bytes up through byte 126. Suppose Host A then sends two segments to Host B back-to-back (See the figure below). The first and second segments contain 80 and 40 bytes of data respectively. In the first segment, the sequence number is 127, the source port number is 302, and the destination port number is 80. Host B sends an acknowledgment whenever...
Host A and B are communicating over a TCP connection. The initial sequence number at Host...
Host A and B are communicating over a TCP connection. The initial sequence number at Host A is 2171. Host A opens the connection, sends three segments, the second of which carries 400 bytes of data, and closes the connection. In the segment sent by Host A, source port number is 303, and the destination port number is 80. ) What is the value of the sequence number of the SYN segment? (1.5 marks) ) What is the value of...
Host A and B are communicating over a TCP connection. The initial sequence number at Host...
Host A and B are communicating over a TCP connection. The initial sequence number at Host A is 2171. Host A opens the connection, sends three segments, the second of which carries 400 bytes of data, and closes the connection. In the segment sent by Host A, source port number is 303, and the destination port number is 80. ) What is the value of the sequence number of the SYN segment? (1.5 marks) ) What is the value of...
In an organization there are four Hosts (i.e. Host A, Host B, Host C and Host...
In an organization there are four Hosts (i.e. Host A, Host B, Host C and Host D) connected to a Router (i.e. Router0). Explain in your own words (a) what happens when each of the four Hosts send a broadcast (b) How many broadcast domains are on the Router0? (c) If the Router (i.e. Router0) is replaced by a hub, how many broadcast domains are on the hub? (d) If the Router (i.e. Router0) is replaced by a switch, how...
Which TCP/IP parameters must be defined for a host to be able to communicate with hosts...
Which TCP/IP parameters must be defined for a host to be able to communicate with hosts on a remote network? Hint: There are three. Please answer in 10m as IT'S URGENT!!! WILL DEFINITELY BE UPVOTED!
1. Assume that total has already been declared as a double variable and received a value,...
1. Assume that total has already been declared as a double variable and received a value, and discountRate has been declared as a double variable, you don’t need to declare them again. You write one if statement (not multiple individual if statements) for following requirements. when total is less than 50, set discountRate to 0.0; when total is equal to or greater than 50 and less than 100, set discountRate to 0.05; when total is equal to or greater than...
5. Holly has received various gifts over the years. She has decided to dispose of the...
5. Holly has received various gifts over the years. She has decided to dispose of the following assets she received as gifts (assume for each of the gift transactions that no gift tax paid). Please answer the questions for each alternative scenario. a. In 1997, she received a land worth $98,000. The donor's adjusted basis was $ 110,000. Holly sells the land for $102,000 in 2017. Gift property basis: Holly’s gain/loss on the sale: b. In 2001, she received stock...
You are considering investing in a new project, Project B. Your firm has already invested in...
You are considering investing in a new project, Project B. Your firm has already invested in one project, Project A. If the cash flows to Project A will increase when you invest in Project B, should you include the entire cash flows to Project A in your valuation of Project B, include the new cash flows to Project A in the valuation of Project B, or exclude any cash flows to Project A in the valuation of Project B? Explain...
1. You are considering investing in a new project, Project B. Your firm has already invested...
1. You are considering investing in a new project, Project B. Your firm has already invested in one project, Project A. If the cash flows to Project A will increase when you invest in Project B, should you include the entire cash flows to Project A in your valuation of Project B, include the new cash flows to Project A in the valuation of Project B, or exclude any cash flows to Project A in the valuation of Project B?...
Criminal profiling has received a lot of media attention over the past few years. Describe the...
Criminal profiling has received a lot of media attention over the past few years. Describe the process of criminal profiling and the different approaches. What is your opinion of criminal profiling? Is it effective? Use examples from the research literature to support your comments.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT