Starting from:

$30

Assignment 3: CMPT 371 

Assignment 3: CMPT 371 
1) [24 points] Refer to the TCP state machine in the class notes (given below). Assume that a TCP
connection between stations A(client) and
B(server) has been in use. This connection was
established using an active-passive open.
Explain how the connection can be closed
using an active close initiated by the client. To
help you explain draw the series of segments
exchanged during the active close for each of
the three possible paths through the state
machine (from stat ESTAB to state CLOSED).
To indicate the type of diagram desired a
SAMPLE DIAGRAM of the desired type is
shown below the state machine. If you happen
to be interested the sample diagram is for and
active-active (peer-peer) open
SAMPLE DIAGRAM
 A B
A sends SYN and
Piggyback ACK
to B’s SYN
A sends
SYN B sends SYN
B sends SYN and Piggyback
ACK to A’s SYN
Both stations start in state CLOSEDBoth stations move to state SYN SENTBoth stations move to state SYN
Both stations move to state ESTABA receives ACK
 of its own FIN B receives ACK of its own
FIN
2) Consider the figure shown below. Assuming TCP (Reno) is using congestion control (slow start and
congestion avoidance modes as discussed in your text and in class) answer the following questions.
Assume the system was running before the sample window length data shown in the plot below was
collected. Assume the first value of ssthresh shown on the diagram is 64.
Point 1 is asumed to be at the beginning of interval 1. If a failure that causes transition between
modes occurs between two points the first point is considered to be part of the pre-failure mode, the
second point to be part of the post failure mode. For other transitions between modes (slow start,
congestion avoidance) one point is a part of both modes. It is both the end of one mode and the
beginning of the other. For example point 13 below would be part of both modes.
 For each question you should provide a short discussion justifying your answer.
a) [4 points] Identify the periods of time when TCP collision avoidance is operating
b) [4 points] Identify the periods of time when TCP slow start is operating
c) [3 points] During the 6th transmission round, is segment loss detected by a triple duplicate
ACK or by a timeout? What is the value of ssthresh
d) [3 points] During the 22nd transmission round, is segment loss detected by a triple duplicate
ACK or by a timeout?
e) [10 points] What is the value of ssthresh and the size of the congestion window during the 4th
transmission round? During the 16th transmission round? During the 27th round? During the
35th round? During the 39nd round? NOTE: The value of the size of the congestion window
during the 4th transmission round is the value at the beginning of the 4th transmission round.
0
5
10
15
20
25
30
35
40
45
50
55
60
65
70
75
80
85
90
95
1 3 5 7 9 11 13 15 17 19 21 23 25 27 29 31 33 35 37 39 41 43 45CONGESTION WINDOW SIZE (SEGMENTS)
TRANSMISSION ROUND
Explain how the values of ssthresh and the congestion window size are determined at each
change in the value of ssthresh. The first value of ssthresh (at point 1) is given and need not be
discussed.

round Ssthresh Congestion window size
4
16
27
35
39
f) [2 points] During what transmission round is the 270th segment sent? The 1300th segment?
Include the segments sent in transmission round 1.
3) Consider two hosts transferring data using a TCP connection. Assume the connection between hosts
A and B has already been made. The establishment of the TCP connection is not a part of this problem.
Host A is sending a stream of application data to host B. The first octet of data A is sending to B in
the transfer of data illustrated below is octet 3453. Each packet sent by A contains 550 octets of data.
Host B is sending a different stream of application data to host A. The first octet of data B is sending
to A in the transfer of data illustrated below is 7777. Each packet B is sending to A contains 400 octets
of data.
a) [15 points] Fill in the sequence numbers and acknowledgement number on the diagram below.
b) [5 points] What are the two TCP error control control mechanisms shown below? These are the
mechanisms that help recover from loss of packets or ACKs.
c) [10 points] Give a step by step description of how the first mechanism you identified in b)
operates using the diagram as an example to help in your explanation.
d) [10 points] Give a step by step description of how the second mechanism you identified in b)
operates using the diagram as an example to help in your explanation.

SEQ NUM ACK NUM SEQ NUMACK NUM3453 7777 A B
4) Consider the CIDR routing table shown below.
Destination Gateway Mask Interface
192.168.48.0 * 255.255.240.0 eth1 Line 1
192.168.4.0 * 255.255.254.0 eth2 Line 2
192.168.0.0 * 255.248.0.0 eth3 Line 3
120.124.160.0 192.168.0.2 255.255.224.0 eth3 Line 4
192.156.32.0 128.168.48.1 255.255.255.0 eth1 Line 5
0.0.0.0 192.168.200.12 0.0.0.0 eth4 Line 6
a) [5 points] Is the forwarding table (routing table) above optimized so that the first match found is
the “best” match? Explain why or why not
b) [15 points] For each address in the table below which line in the routing table on the previous
page is used, which interface is the packet sent through, and what the IP address of the host the
packet will be sent to in the Ethernet layer? Fill in the table below
Destination address Line in
forwarding
table
Interface Next hop IP address
192.168.5.55
192.168.6.3
192.168.55.12
192.156.33.1
120.124.160.12 

More products