Homework 3

  1. Page 285, 1, 2, 3, 4, 5
  2. Page 287: 12, 20, 21, 25, 27, 29, 30, 32
  3. Make a state diagram of TCP that shows the size of the congestion window and includes timeout, ACK arrivals. Neglect the receiver window.
  4. Suppose that a host sends a TCP packets and each packet has exactly one byte of data. Now suppose that the host send a packet with sequence number equal to 10. When this packet reaches the destination, the destination generates an ACK. Which of the following ACK numbers might the destination generate. Make a timing diagram for each case.
    1. Ack Number = 9
    2. Ack Number = 10
    3. Ack Number = 11
    4. Ack Number = 12
  5. Suppose that the slowest link between a source and destination is 100Mbps.
    1. If ACK-clocking is working, what is the maximum bit-rate that the source will send packets?
    2. Now suppose that RTT = 100ms. If the source sends at this maximum bit-rate, what is the congestion window (cwnd) size?
    3. If the initial size of cwnd is 1000B and MSS = 1000B, and TCP is in slow-start with SSThresh=infinity, how long does it take for cwnd to reach the optimal window size?
    4. If the initial size of cwnd is 1000B and TCP is in congestion avoidance, how long does it take for cwnd to reach the optimal window size?
  6. Assume that a TCP connection has a window size of 8 and there are no unacknowledged packets. Show the timing diagram for TCP-RENO when the fourth packet send is lost. Show the timing until the window reaches 5.
  7. SYN Attack
    1. Suppose that the initial value of RTO is 3 sec., and RTO is multplied by two if a packet loss occurs.
    2. Suppose that a TCP server will only resend a SYN-ACK four times if an ACK does not arrive before RTO after the previous SYN-ACK was sent.
    3. Suppose that the server reseves 100KB of memory when a SYN arrives, and frees the memory after the connection ends, the connection is reset, or the connection fails (e.g., if no response for the SYN-ACK arrives).
    4. Finally, suppose that the server is connected via 10 Mbps link and SYN packets are 40B.
    5. How large must be server's memory be to withstand a SYN attack?
  8. If a file is 4 packets long, how long does it take to open a connection and transfer the file via TCP when RTT = 200ms? How long does it take if RTT=20ms? What controls the time to download a small file, RTT or link bit-rate?