Interactive end-of-chapter exercises


Supplement to Computer Networking: A Top Down Approach 8th Edition


"Tell me and I forget. Show me and I remember. Involve me and I understand." Chinese proverb

Textbook Cover

The HTTP GET message

Consider the figure below, where a client is sending an HTTP GET message to a web server, gaia.cs.umass.edu




Suppose the client-to-server HTTP GET message is the following:

GET /kurose_ross_sandbox/interactive/quotation6.htm HTTP/1.1
Host: gaia.cs.umass.edu
Accept: text/plain, text/html, image/gif, image/jpeg, audio/mpeg, audio/vnf.wave, video/mpeg, video/mp4,
Accept-Language: en-us, en-gb;q=0.9, en;q=0.2, fr, fr-ch, de
If-Modified-Since: Tue, 03 Aug 2021 16:31:51 -0700
User Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/535.11 (KHTML, like Gecko) Chrome/17.0.963.56 Safari/535.11



Question List


1. What is the name of the file that is being retrieved in this GET message?

2. What version of HTTP is the client running?

3. True or False: The client will accept html files

4. True or False: The client will accept jpeg images

5. What is the client's preferred version of English?

6. What is the client's least preferred version of English?

7. True or False: The client will accept the German language

8. True or False: The client already has a cached copy of the file




Solution


1. The name of the file is quotation6.htm.

2. The client is running on HTTP/1.1

3. True. In the 'Accept' field the client includes 'text/html' files.

4. True. The client does include 'image/jpeg' in its 'Accept' field.

5. The client's preferred version of English is American English. Any language without a defined q value has a default value of 1

6. The client's least preferred version of English is English because it has the lowest q value.

7. True. The client does include German in its 'Accepted-Language' field.

8. True. The client has a cached copy of the file that was updated on: Tue, 03 Aug 2021 16:31:51 -0700



That's incorrect

That's correct

The answer was: quotation6.htm

Question 1 of 8

The answer was: HTTP/1.1

Question 2 of 8

The answer was: True

Question 3 of 8

The answer was: True

Question 4 of 8

The answer was: American English

Question 5 of 8

The answer was: English

Question 6 of 8

The answer was: True

Question 7 of 8

The answer was: True

Question 8 of 8

Try Another Problem

We gratefully acknowledge the programming and problem design work of John Broderick (UMass '21), which has really helped to substantially improve this site.

Copyright © 2010-2021 J.F. Kurose, K.W. Ross
Comments welcome and appreciated: kurose@cs.umass.edu