05 - Application Layer

Problem 1: Short Answer Questions

Problem 2: Dynamic Host Configuration Protocol

We discussed in class that a host’s IP address can either be configured manually, or by Dynamic Host Configuration Protocol (DHCP).

Problem 3: Video Streaming Protocol Selection

Consider an application where a camera at a highway is capturing video of the passing cars at 30 frames/second and sending the video stream to a remote video viewing station over the Internet. You are hired to design an application-layer protocol to solve this problem. Which transport-layer protocol, UDP or TCP, would you use for this application and why? Justify your answer.

View Answer

UDP is preferred for real-time video streaming because it is delay-sensitive and can tolerate packet loss. UDP avoids retransmissions, congestion control delays, and head-of-line blocking present in TCP, resulting in smoother playback.

Problem 4: DNS Recursive vs Iterative Queries

Consider a host H within qc.cuny.edu domain, whose name server is ns.qc.cuny.edu. Suppose that H tries to learn the IP address of the host ringding.cs.umd.edu. Assume that ns.qc.cuny.edu does not have the IP address of ringding.cs.umd.edu in its cache. Further assume that root DNS servers only know the authoritative name server for umd.edu domain.

Problem 5: DNS and HTTP Web Page Retrieval

Suppose within your Web browser you click on a link to obtain a Web page. Suppose that the IP address for the associated URL is not cached in your local host so that a DNS look-up is necessary to obtain the IP address. Suppose that $n$ DNS servers are visited before your host receives the IP address from DNS; the successive visits incur RTTs of $RTT_1, RTT_2, \ldots, RTT_n$. Let $RTT_0$ be the RTT between your local host and the Web server containing the Web page and let $B$ bits/sec be the sustained bandwidth.

Problem 6: Instant Messaging System Architecture

Suppose you were to implement an instant message such as Yahoo messenger, which allows any number of users to exist in the system and establish instant messaging sessions among them.

Problem 7: Web Proxy Caching Performance

Assume that Queens College decided to use a Web Proxy, i.e., a Web cache. In this model, each Web browser is set up to send their requests to the Web proxy rather than sending the request directly to the actual Web server. Recall that a Web browser also maintains a local cache. Suppose a user accesses 100 objects one after the other using HTTP/1.0. The size of each object is 10000 bits. Assume that the sustained bandwidth between the user’s PC and the Web Proxy is 10Mbps and has an RTT of 1ms, and the sustained bandwidth between the Web proxy and a Web server is 1Mbps and has an RTT of 100ms.

Problem 8: Alert Notification Protocol Selection

Consider a network-attached burglar alarm which is programmed to notify the police when a burglar enters the house. Suppose that you are to use either HTTP or SMTP to send the notification message. How would you use each protocol to send the message? Which protocol makes more sense to use for this application?

View Answer

SMTP is preferable to HTTP for alarm notifications because it provides reliable store-and-forward delivery.

Problem 9: Email with MIME Attachments

Suppose you want to send an e-mail message M with 4 attachments, A1, A2, A3 and A4. Describe how your e-mail client, e.g., Outlook, would send this e-mail?

View Answer

The client constructs a MIME multipart message with Base64-encoded attachments and sends it using SMTP.

Problem 10: POP3 and IMAP Mail Protocols

What are POP3 and IMAP used for? What are the advantages of IMAP over POP3?

View Answer

POP3 downloads email locally, while IMAP keeps email on the server and supports synchronization and folders, making IMAP more flexible.