CSE 342: Project 2 - Reliable Data Transfer

Due: Thursday 15 October and Sunday 18 October 2009 (via BlackBoard)

Purpose: Review and strengthen understanding of reliable data transfer protocols.

In this project, you will implement two reliable transport protocols. Kurose and Ross originally titled this as "Programming Assignment 5: Implementing a Reliable Transport Protocol" and provide two versions: the Alternating-Bit-Protocol version and the Go-Back-N version.

Your goal is to write routines for the sender and receiver to be able to transfer a file over an unreliable network. Updated instructions are available locally (but the original is also available from the book's website, here). Be certain to look at the diagram, and the helpful hints at the end. Show the successful operation of your code in the presence of packet loss.

Instead of using their prog2.c, use the local version (but ignore any mentions of extra credit). It has been slightly modified so that, among other things, it does not generate any compiler warnings (on our Suns running Solaris 10, at least) and fixes a random number generator problem.

In both parts of this project you will need to turn in a code listing (documented appropriately!) and sample output (captured using stdout redirection) for both versions, as described in the online project description. In particular, for each part hand in output for a run that is long enough so that at least 20 messages were successfully transfered from sender to receiver (i.e., the sender receives ACK for these messages), using a loss probability of 0.1, a corruption probability of 0.05, and a trace level of 2.

For Project 2a:

For Project 2b:

Runs for both assignments must not include any additional calls to srand() so that everyone's traces will use the same random number sequence (initialized by the simulator with a 9999 seed). You are encouraged use different seeds while under development and testing.

Please highlight the important parts of the sample output by incorporating a string of four exclamation points (!!!!). While you may develop your solution to this project on any platform, if there is any question, your code must work on the Suns.


Last modified: 28 September 2009