Fishnet Assignment 4: Reliable Transport

Due: Monday Nov. 19, 2001 at the beginning of class. Out: Monday Nov. 5, 2001.

CSE/EE461 Autumn 2001; Wetherall.

In this assignment, you will work in teams of two to develop a Fishnet node that reliably transfers files to other nodes. The program you write builds on your solution so far. The goal of this assignment is for you to understand reliable transport.

  1. What You Need To Write

Write a C program in a single file called hw4.c that does the following:

You should read about and call flush()after printing single letter codes so that they appear on the console without delay. If you print the codes as specified above, a successful connection will appear as a sequence of mostly dot characters marching over your screen.

  1. Step-by-Step Development and Test Instructions

Here is a suggested set of steps to develop the required functionality.

  1. Start with hw3.c by copying it to the new file hw4.c
  2. Run the fishhead with high loss (try "--help" or just "—loss 0.2") to stress the reliability mechanisms.
  3. Code the "sendfile" command syntax, but just send a series of dummy text packets reliably (letting the first received packet start the connection and handling acknowledgement and retransmission as necessary) and print them out to the console at the receiver.
  4. Add connection setup and teardown code at both sender and receiver, plus the print messages, and test a dummy transfer.
  5. Add the file transfer code by letting the first packet carry the filename, reading from the input file at the sender and writing to the output file at the receiver, keeping track of bytes transferred and printing the remaining messages.
  6. Test your program for interoperability with the class reference solution in preparation for joining the class Fishnet.
  7. You’re done! Read and do any turnin work now.
  8. For Fun. Implement the ability to handle multiple concurrent connections by replicating the connection state.
  9. For Fun. The acknowledgement rules are defined in such a way that your sender can support a larger sliding window of 8 packets (say) without any change in the receiver code. So make your sender use a larger sliding window and see how much faster it is.
  1. Turn In and Discussion Questions

This time, you turn in your program source code by transferring it over the Fishnet to our node. You hand in a paper copy of the discussion questions and test cases below as well as your source code.

 

  1. Turn in your program by transferring it to our node running on the class Fishnet. We will send details including what name to use on the class mailing list. (2 points for successful transfer.)
  2. The above turnin is the test case. Save the output and print it for us, along with a paper copy of your program. (12 points for the program itself and demonstration of how it works via the test case output.)
  3. Question (2 points): What difference (advantage or disadvantage in terms of reliability) does having a SYN flag make compared to simply using a sequence number of one to signify the start of a new connection?
  4. Question (2 points): What difference (advantage or disadvantage in terms of reliability) does having a FIN flag make compared to simply not signaling FIN and letting old state be deleted as it is already?
  5. Question (2 points): In what ways does the system you have built fall short of perfect reliable file transfer? You should assume that the data in packets is protected by a 32 bit checksum while in transit (and this is in fact the case).

Note: There are specific, short answers to the above questions. Don’t write much!

 

—END—