0% found this document useful (0 votes)
4 views10 pages

HTTP Analysis Report for CS-311 Task

Uploaded by

dabaci3568
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
4 views10 pages

HTTP Analysis Report for CS-311 Task

Uploaded by

dabaci3568
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

UNIVERSITY OF ENGINEERING AND TECHNOLOGY,

PESHAWAR PAKISTAN
Main Campus

CS-311 Web Programming


Task . 02
Submitted By
Name: [Link] NOOR
Registration No. 21PWBCS0837
Semester: 5th
Section: A
Submission Date: 09/oct/2023

Submitted To Dr Syed Adeel Ali Shah

DEPARTMENT OF COMPUTER SCIENCE & IT


UNIVERSITY OF ENGINEERING AND TECHNOLOGY, PESHAWAR, PAKISTAN

1. Is your browser running HTTP version 1.0 or 1.1? What version of HTTP is the server
running? HTTP 1.1 (see screenshot)

2. What languages (if any) does your browser indicate that it can accept to the server?

en-US(US English) as shown in prior screenshot

What is the IP address of your computer? Of the [Link] server?


My computer is [Link] (this is a virtual IP address assigned by my virtual machine
software) and the destination is [Link]. See prior screenshot. 3. What is the
status code returned from the server to your browser?

200 OK (see prior screenshot)


4. When was the HTML file that you are retrieving last modified at the server?

We can filtermessages by http.last_modified and we see that the HTTP response I


received for the html file doesn’t show this field. We do have a http.last_modified field
in the favicon response however, as shown in the screenshot below. This says the favicon
was last modified on Feb 25, 2010.

5. How many bytes of content are being returned to your browser?

Content-length = 209 [Link] screenshot below.


6. By inspecting the raw data in the packet content window, do you see any headers
within thedata that are not displayed in the packet-listing window?
If so, name one. No. The raw data appears to match up exactly with what is shown in
the packet-listing window.

7. Inspect the contents of the first HTTP GET request from your browser to the server. Do
yousee an “IF-MODIFIED-SINCE” line in the HTTP GET?

No.
8. Inspect the contents of the server response. Did the server explicitly return the contents
ofthe file? How can you tell? See screenshot of response with Alice’s Adventures...
9. Now inspect the contents of the second HTTP GET request from your browser to the
[Link] you see an “IF-MODIFIED-SINCE:” line in the HTTP GET? If so, what
information follows the “IF-MODIFIED-SINCE:” header?
Yes.
If-Modified-Since: Wed, 12 Mar 2014 17:29:08 GMT\r\n.
See screenshot below.
10. What is the HTTP status code and phrase returned from the server in response to this
secondHTTP GET? Did the server explicitly return the contents of the file? Explain.

As seen in the previous screenshot, we get a HTTP/1.1 304 Not Modified Response. This
is much shorter than the full response packet seen previously which contained all of
Alice in Wonderland.
11. How many HTTP GET request messages were sent by your browser (again, ignoring
requestsfor [Link])?

Just one.
12. How many data-containing TCP segments were needed to carry the single HTTP
response?

From the screenshot below, there are 4 TCP segments.


13. What is the status code and phrase associated with the response to the HTTP GET
request?

HTTP/1.1 200 OK (as seen in previous screenshot)


14. Are there any HTTP status lines in the transmitted data associated with a TCP-
induced“Continuation”?

No.
15. How many HTTP GET request messages were sent by your browser?

To which Internetaddresses were these GET requests sent? Three: [Link],


[Link], [Link]. See screenshot below.
16. Can you tell whether your browser downloaded the two images serially, or whether
they weredownloaded from the two web sites in parallel? Explain.
Based on the timestamps, it appears the images were downloaded serially. Also, the
source port is incrementing each time from 64444, 64445, 64446 which means that the
images were received serially over separate TCP connections.
17. What is the server’s response (status code and phrase) in response to the initial HTTP
GETmessage from your browser?

HTTP/1.1 401 Authorization Required (see screenshot below)


18. When your browser’s sends the HTTP GET message for the second time, what new
field isincluded in the HTTP GET message?

Authorization field. See screenshot below.


19. Copy the string of text that appears after “Authorization: Basic ”, and enter it into the
Base64 decoder here – [Link]
Make sure to click on “decode”. To what ASCII string does the Base64 string decode
to? (Hint: you should see the username and password for the course website
embedded in the string).

No need since Wireshark has already done the decoding. See the previous screenshot. Our
credentials are clearly visible in wireshark

Common questions

Powered by AI

By inspecting headers such as 'If-Modified-Since', 'Last-Modified', and 'Cache-Control', one can determine if caching mechanisms are used. An 'If-Modified-Since' header indicates client-side caching requests, while a 304 Not Modified response from the server confirms that it is employing conditional get requests to manage resources efficiently .

A 401 Authorization Required status is returned when a requested resource requires authentication and the request lacks valid credentials . The client typically responds by resending the request with appropriate credentials included in an Authorization header, potentially using credentials provided through a user interface prompt.

Four TCP segments were required to carry the single HTTP response . This suggests that the response was relatively large and had to be broken into several parts to fit within the TCP segment size limits, indicating substantial content or resource size.

A 304 Not Modified response is returned when the client sends a conditional GET request with an 'If-Modified-Since' header, and the requested resource has not been modified since the specified date . This response reduces unnecessary data transfer, lowering bandwidth usage and improving load times, which is particularly beneficial for clients with slow internet connections or limited data plans.

The browser and server are both using HTTP 1.1 . This version includes several improvements over HTTP 1.0, such as persistent connections by default, where multiple requests and responses can be sent over a single TCP connection, reducing latency and the overhead of additional connections.

If the browser is sending images serially, indicated by incrementing source ports, it suggests that each image is being sent over a separate TCP connection one after the other, rather than concurrently . This could be due to network protocol settings, server limitations, or client configuration that does not support simultaneous connections, potentially leading to increased loading times.

Transmitting unencrypted credentials in an Authorization header poses significant security risks, as these credentials can be intercepted by unauthorized parties through man-in-the-middle attacks . This highlights the importance of using HTTPS to encrypt traffic, thus protecting sensitive information in transit.

The presence of an 'If-Modified-Since' header allows the server to send a 304 Not Modified status, indicating that the cached version of the resource is still valid and there's no need to resend the resource, thus saving bandwidth . In its absence, the server typically processes the request without caching optimizations, potentially leading to unnecessary data transmission.

You might also like