HOMEWORK 2
1. Imagine that you are trying to visit www.enterprise.com, but you don't remember
the IP address the webserver is running on.
Assume the following records are on the TLD DNS server:
(www.enterprise.com, dns.enterprise.com, NS)
(dns.enterprise.com, 146.54.224.15, A)
Assume the following records are on the enterprise.com DNS server:
(www.enterprise.com, east2.enterprise.com, CNAME)
(east2.enterprise.com, 142.81.17.206, A)
(enterprise.com, mail.enterprise.com, MX)
(mail.enterprise.com, 247.29.162.145, A)
Figure 1
Assume your local DNS server only has the TLD DNS server cached.
a. What transport protocol(s) does DNS use: TCP, UDP, or Both?
b. What well-known port does DNS use?
c. In the above example, how many unique types of Resource Records (RR)
are there at the authoritative enterprise.com DNS server?
d. Can you send multiple DNS questions and get multiple RR answers in one
message? Answer with Yes or No
e. To which DNS server does a host send their requests to? Answer with the
full name
f. Which type of DNS server holds a company's DNS records? Answer with the
full name
g. In the example given in the problem, what is the name of the DNS server for
enterprise.com?
h. When you make the request for www.enterprise.com, your local DNS
requests the IP on your behalf. When it contacts the TLD server, how many
answers (RR) are returned?
i. In the previous question, there were two responses, one was a NS record
and the other an A record. What was the content of the A record? Answer
with the format: "name, value" -
j. Assuming that the enterprise.com website is actually hosted on
east2.enterprise.com, what type of record is needed for this? –
k. Now imagine we are trying to send an email to admin@enterprise.com, and
their mail server has the name mail.enterprise.com. What type of record will
contain the name of the enterprise.com domain and the name of its
mailserver(s)?
l. In that MX record, what are the contents? Answer with the format: "name,
value"
m. Does your local DNS server take advantage of caching like web requests?
Answer with Yes or No
2. Assume that a user is trying to visit gaia.cs.umass.edu, but his browser doesn't
know the IP address of the website. In this example, examine the difference
between an iterative and recursive DNS query.
Figure 2
a. Between steps 1 and 2, where does the Local DNS server check first? Answer
with 'User', 'DNS Local', 'DNS Root', 'DNS TLD', or 'DNS Authoritative'.
b. Between steps 2 and 3, assuming the root DNS server doesn't have the IP we
want, where does the response link? Answer with 'DNS Local', 'DNS Root', 'DNS
TLD', or 'DNS Authoritative'.
c. Between steps 4 and 5, assuming the TLD DNS server doesn't have the IP we
want, where does the response link? Answer with 'DNS Local', 'DNS Root', 'DNS
TLD', or 'DNS Authoritative'.
d. Between steps 6 and 7, the authoritative DNS server responds with the IP we
want. What type of DNS record is returned?
e. Which type of query is considered best practice: iterative or recursive?
3. Suppose within your Web browser you click on a link to obtain a Web page. The IP
address for the associated URL is not cached in your local host, so a DNS lookup
is necessary to obtain the IP address. Suppose that three DNS servers are visited
before your host receives the IP address from DNS. The first DNS server visited is
the local DNS cache, with an RTT delay of RTT 0 = 3 msecs. The second and third
DNS servers contacted have RTTs of 17 and 27 msecs, respectively. Initially, let's
suppose that the Web page associated with the link contains exactly one object,
consisting of a small amount of HTML text. Suppose the RTT between the local
host and the Web server containing the object is RTT HTTP = 41 msecs.
Figure 3
a. Assuming zero transmission time for the HTML object, how much time (in msec)
elapses from when the client clicks on the link until the client receives the
object?
b. Now suppose the HTML object references 2 very small objects on the same
server. Neglecting transmission times, how much time (in msec) elapses from
when the client clicks on the link until the base object and all 2 additional
objects are received from web server at the client, assuming non-persistent
HTTP and no parallel TCP connections?
c. Suppose the HTML object references 2 very small objects on the same server,
but assume that the client is configured to support a maximum of 5 parallel TCP
connections, with persistent HTTP.
d. What's the fastest method we've explored: Nonpersistent-serial, Nonpersistent-
parallel, or Persistent-parallel?
4. Consider the figure below, where a client is sending an HTTP GET message to a
web server, gaia.cs.umass.edu
Figure 4
Suppose the client-to-server HTTP GET message is the following:
GET /kurose_ross_sandbox/interactive/quotation3.htm HTTP/1.0
Host: gaia.cs.umass.edu
If-Modified-Since: Mon, 28 Oct 2024 21:20:29 -0700
a. What is the name of the file that is being retrieved in this GET message?
b. What version of HTTP is the client running?
c. True or False: The client already has a cached copy of the file
5. Consider the figure below, where a client is sending an HTTP GET message to a
web server, gaia.cs.umass.edu
Figure 5
Suppose the client-to-server HTTP GET message is the following:
GET /kurose_ross_sandbox/interactive/quotation10.htm HTTP/1.1
Host: gaia.cs.umass.edu
Accept: text/plain, text/html, text/xml, image/jpeg, image/png, audio/basic, audio/mp4,
video/mpeg, video/wmv,
Accept-Language: en-us, en-gb;q=0.2, en;q=0.7, fr, fr-ch, zh, de, fi
If-Modified-Since: Mon, 28 Oct 2024 23:06:45 -0700
User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_7_3) AppleWebKit/534.53.11
(KHTML, like Gecko) Version/5.1.3 Safari/534.53.10
a. What is the name of the file that is being retrieved in this GET message?
b. What version of HTTP is the client running?
c. True or False: The client will accept html files
d. True or False: The client will accept jpeg images
e. What is the client's preferred version of English?
f. What is the client's least preferred version of English?
g. True or False: The client will accept the German language
h. True or False: The client already has a cached copy of the file
6. Consider the figure below, where the server is sending a HTTP RESPONSE
message back to the client.
Figure 6
Suppose the server-to-client HTTP RESPONSE message is the following:
HTTP/1.0 404 Not Found
Date: Tue, 29 Oct 2024 06:25:52 +0000
Server: Apache/2.2.3 (CentOS)
Content-Length: 612
Connection: Close
Content-type: text/html
a. Is the response message using HTTP 1.0 or HTTP 1.1?
b. Was the server able to send the document successfully? Yes or No
c. Is the connection persistent or nonpersistent?
d. What is the type of file being sent by the server in response? - text/html
e. What is the name of the server and its version? Write your answer as
server/x.y.z
f. Will the ETag change if the resource content at this resource location
changes? Yes or No
7. Consider an HTTP server and client as shown in the figure below. Suppose that the
RTT delay between the client and server is 20 msecs; the time a server needs to
transmit an object into its outgoing link is 1 msecs; and any other HTTP message
not containing an object has a negligible (zero) transmission time. Suppose the
client again makes 60 requests, one after the other, waiting for a reply to a request
before sending the next request.
Figure 7
Assume the client is using HTTP 1.1 and the IF-MODIFIED-SINCE header line.
Assume 50% of the objects requested have NOT changed since the client
downloaded them (before these 60 downloads are performed)
a. How much time elapses (in milliseconds) between the client transmitting
the first request, and the completion of the last request?
Figure 8
8. Refer to Figure 8 and answer the following questions.
Figure8 shows an institutional network connected to public Internet and the
assumptions as stated below:
•Average object size: 4Mbits,
•Average request rate from browsers to origin servers: 25 request/s,
•Access link rate: 100 Mbps,
•Access LAN rate: 1Gbps.
a. Without web cache server, calculate access link utilization. [2m]
b. Assume the access link rate is increased to 200Mbps. Without web cache
server, calculate the access link utilization. [2m]
c. Assume the link capacity is unchanged (100Mbps) and a web server cache is
used which has a hit rate of 40%, find the access link utilization. [2m]
d. Compare the results in (b) and (c). What is your conclusion? [2m]
9. The diagram below shows how the HTTP cookies keep user state between client
and server. For each point highlighted by the number, identify the content of the
HTTP request or response message.
___ (1) ___ /index.html HTTP/2.0
User-Agent: Firefox/3.6.10
At point A Host: www.amazon.com
Accept-Language: en-us
Accept-Encoding: gzip, deflate
Connection: Keep-Alive
HTTP/2.0 ____ (2) ___
At point B Content-Type: text/html
Set-Cookie: ____ (3) ____
[page content]
___ (4) ___ /index.html/bag.jpg HTTP/2.0
At point C
Host: ____ (5) ____
Cookie: ____ (6) ____
At point D ___(7)___ /index.htm ___(8)___
User-Agent: Firefox/3.6.10
Host: ____(9)____
Accept-Language: en-us
Accept-Encoding: gzip, deflate
Connection: Keep-Alive
Cookie: ____(10)____
___ (1) ___ /index.html HTTP/2.0
User-Agent: Firefox/3.6.10
At point A Host: www.amazon.com
Accept-Language: en-us
Accept-Encoding: gzip, deflate
Connection: Keep-Alive
HTTP/2.0 ____ (2) ___
At point B Content-Type: text/html
Set-Cookie: ____ (3) ____
[page content]