Server CGI - Quiz Explanation

The answers you selected are indicated below, along with text that explains the correct answers.
 
1. Use this HTTP request to answer the following questions:
GET /program.cgi?foo=one&bar=two HTTP/1.0
User-Agent: Mozilla/3.01 (Win95; I)
Referer: https://www.javadeploy.com/xml-programming/module3/business-order-form.html
Host: luna Accept: image/gif, image/x-xbitmap, image/jpeg, image/pjpeg, */*
What object is being requested?
Please select the best answer.
  A. program.cgi
  B. https://www.javadeploy.com/xml-programming/module3/business-order-form.html
  C. Mozilla/3.01
  The correct answer is A. The string /program.cgi?foo=one&bar=two is the URI in the request, but the query part (after the ?) is not technically part of the object being requested.


2. What will be the value of HTTP_USER_AGENT?
Please select the best answer.
  A. https://www.javadeploy.com/xml-programming/module3/business-order-form.html
  B. (Win95; I)
  C. Mozilla/3.01 (Win95; I)
  The correct answer is C. Each of the header lines from the request are made into environment variables by adding HTTP_ to the beginning of them. Thus User-Agent becomes HTTP_USER_AGENT.


3. What variable will have the value luna?
Please select the best answer.
  A. HTTP_HOST
  B. User-Agent
  C. HTTP_GET
  The correct answer is A. Using the same reasoning as in the previous question, the Host: header becomes HTTP_HOST.