Reference no: EM133003317
Active: UDP - Unreliable Data Protocol?
The learning objectives of this class is to learn why we need transport layer in networking and explore a lightweight transport layer protocol, User Datagram Protocol (UDP). Yes, the name is not "unreliable Data Protocol."
At the end of this activity, you should be able to:
1. Explain the use of transport layer protocol and the difference between UDP and TCP
2. Understand the UDP packet structure.
3. Build a simple client-server application that employs UDP, using socket programming in Python.
This class activity is designed to be worked through active participation and collaborating with peers under the guidance of the teaching team in the class. The active classes are designed to be interactive, and they are here for you to extend your learning. However, these classes will only help you to enhance your learning if you come prepared. To work on the class activities, you will be expected to have completed first half of the Transport Layer module. You need to have a basic understanding of layered model, TCP/IP, transport layer, and UDP. If you are not familiar with any of the above, please head back to the CloudDeakin unit site and complete the relevant modules before starting this active class.
The active classes are related to assessment tasks on OnTrack. After learning about different concepts from the content provided in the unit site, you will expand on this knowledge by working on activities designed to put these concepts in practice during the active classes and submit the completed task to OnTrack in the same week. The teaching team will guide and support your learning during these activities. This will help you manage your time and tasks better to avoid tasks piling up towards the deadlines. If you do not complete these activities in class, you will need to work on them in your own time, with limited support available from us.
This class activity is split into three parts. First, you will conduct a group discussion. Then, you will analyse UDP packets in Wireshark. Finally, you will build a simple client-server application that operates on UDP protocol using socket programming in Python. You need to form a group of four people to conduct the following activities.
Activity 1:
1. Group discussion: Assume that you are helping your friend to move his/her house and your responsibility is to take care of moving goods in the kitchen.
a. What method would you take if your friend needs to pack everything within an hour because the moving truck will be there soon?
b. How would your method change if you have more time and your friend would like to make sure each item in the kitchen is safely delivered, and your friend wants to keep those on the same order it was on the previous house?
c. Now, can you relate the above scenarios to the well-known two transport layer protocols? Consider different scenarios including large file transfer and faster communication.
Activity 2:
1. Open Wireshark to capture packets, open the web browser and use an application that uses UDP (perhaps DNS). Stop the packet capture.
2. Use the filter to display UDP packets (it is UDP segments).
3. Now you are ready to analyze UDP. The following questions can guide you to conduct your analysis. Make sure that you take enough screenshots and notes. You will use those to prepare your task submissions.
a. Pick one UDP packet from the filtered packets. Examine the number of fields that are in the header of the selected UDP packet. You can take a screenshot of the packet and name and explain the fields in the UDP packet.
b. Can you identify the length of each UDP header field from this UDP packet? You can indicate the length in bytes. You may want to examine the displayed information in Wireshark's packet content field.
c. Can you explain the value in the Length field? What exactly this value indicates? You can verify your answer by examining captured UDP packets.
d. Is there a maximum number of bytes that we can include in UDP payload?
e. Can you identify the protocol number given for UDP?
f. Examine two consecutive UDP packets your host sends/receives. Explain the relationship between the port numbers in these two packets.
g. Clear the cache and run another application such as MSTeams while using Web browsing. Capture packets of these two applications. Now you can analyze the captured UDP packets again. Do all UDP packets captured in Wireshark use the same port number? Explain your answer.
Activity3:
In this activity you will learn about data transport with UDP. You will examine socket programming with UDP using Python to build the following simple client-server application. You will do this activity with another group member. You can partner up with a group member to build this simple client-server application. We use PyCharm IDE. If you have not downloaded PyCharm yet, please download PyCharm via the following link and install PyCharm in your laptop/ personal computer.
You will build the following simple client-server application using Python.
- The client should be able to send a message (for example, "Hello SIT") to the server.
- Once the server receives the full message, it counts the number of characters it receives and display the message.
- The server responds to the client by sending the number of characters it received and the same message with uppercase letters.
- The client should receive the number and the message sent by the server.
- The client shows the received message on its terminal.
1. First you need to draw a diagram to explain the operation of the client- server program that uses UDP.
2. Then one of you can develop the client side and the other can develop the server side of the program (you can also develop both end systems and demonstrate the outcome if you chose to do so)
3. You need to show the output of the client- server program to demonstrate that your program works as expected.
Above and Beyond Tasks:
Those who are targeting for Credit and above can complete the following task as part of Task 4.1C and 5.2D to demonstrate your deeper understanding on UDP.
Modified the Python program you wrote to add the following functions:
1. The client sends a message "Hello" to the server
2. Once the server received the full message, sever responds with "Hello, What's your name?"
3. When the client receives the full message from the server, Client should be able to enter the name via the terminal and send the name to the server.
4. When the server received the full message, server responds with "Hello name, Welcome to SIT202". "name" should be the one that is received form the client.
Attachment:- UDP.rar