

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
A programming assignment for cs450: introduction to networking course, where students are required to implement a reliable packet delivery protocol on top of udp. The protocol should ensure reliable delivery of packets by handling lost packets, out-of-order delivery, corrupted packets, and duplicate packets. The assignment consists of two parts: part i focuses on generating packet errors and determining what happened to them, while part ii implements selective repeat for a window size of w packets.
Typology: Assignments
1 / 2
This page cannot be seen from the preview
Don't miss anything!


This assignment is to implement reliable packet delivery protocol on top of UDP. The pro- tocol should ensure reliable delivery of packets given that the types of errors are:
Assuming that the network is able to deliver some packets.
Since the network you’d be using will probably be fairly reliable, you will need to create your own faults. To do this you will write two procedures:
sendUdp does the actual sending of UDP packets and in addition will drop packets, corrupt packets, reorder packets, and duplicate packets. The packet errors can come from a file, specifying what’s to be done, or generated via probabilities and using a random number generator.
receiveUdp receives a UDP packet.
Here the sendUdp routine is part of the sender and the receiveUdp routine is part of the receiver. In addition to the above, the first part of the assignment will also require the program:
The purpose of this code is to generate the packet errors (on the sender side) and then determine what happened (on the receiver side): Recovering from the errors happens in Part II. After the packet is sent the sender waits T time for packet to be acknowledge, and then sets off an alarm. There should be two ways to determine T :
Note that this part is an attempt to deal with random events, both timing and packet errors, in two ways: A deterministic mode to enable testing and a random mode to mimic the real world.
2 Part II
You are to implement selective repeat for a window size of W packets, which is a parameter. You should produce:
3 turnin
The turnin command is:
$ turnin -c cs450 -p a2_part# <cs-login>
The part# refers to the part number of the assignment(part1 or part2). To turnin your source and README files, store them in a directory with the same name as your cs login and turnin the entire directory. Also make sure you include a makefile that creates two executable named sender part# and receiver part# (# is either 1 or 2). (And please do not turnin any binaries or object code).