Professional Documents
Culture Documents
CNLAB Week3
CNLAB Week3
Installation Of Packages
NOTE: The key symbol on the top left of the screen near address tab indicates that the site is
password protected.
Wireshark Capture
Screenshot of abc.php
php file to be displayed
Wireshark Capture
TCP Stream Of HTTP Request-Response
NOTE: As is observed in the 13th and 14th line, cookie is set.
OBSERVATIONS:-
1) BASE 64 ALGORITHM:-
Base64 encoding is used to convert binary data into a text-like format that allows it to be
transported in environments that can handle only text safely. Their applications include
encoding unique ID's for use in HTTP URL's, encoding encryption keys and certificates to
make them safely portable through e-mail amongst many others.
Base64 encoding takes the original data of 3 bytes(24 bits in total) and divides these in packets
of 6 bits each. These 4 new tokens are compiled and then their equivalent from the base64 table
(corresponding to characters from 0-63) is taken and this is how conversion into four printable
characters from the ASCII standard is completed.
For the decoding of Base64 to ASCII, the reverse procedure is applied, i.e. bits of length 24
are divided into 3 tokens of 8 each and the ASCII table is referred for the same.
OBSERVATIONS:-
1) If-Modified-Since was not mentioned in the 1st Request TCP Stream but was
mentioned in the 2nd Request TCP Stream.
2) The server implicitly responded the contents of the file. This can be observed by
the fact that only HTTP Headers are present in the TCP stream of the entire
Request-Response Mechanism whereas the body is blank.
3) Yes, as mentioned previously, in the 2nd HTTP GET Request, the If-Modified-
Since header is present and is followed by the time stamp of when the content in
the first response fetched from the server was last modified.
4) HTTP 304 Not Modified is returned by the server. Content is returned
implicitly(if any).
B) Using Single Image On Server and Not Deleting Cache In Between(EXTRA)
OBSERVATIONS:-
1) If-Modified-Since was neither mentioned in the 1st Request TCP Stream nor in
the 2nd Request TCP Stream.
2) The server explicitly responded the contents of the file. This can be observed by
the fact that along with the HTTP Headers the body content is also present in the
TCP Stream.
3) There was no such If-Modified-Since Header as the contents of the file were
changed midway without clearing the cache.
4) HTTP 200 OK is returned by the server. Content is returned explicitly. Even the
initial image was sent again along with the new image to the client as there was a
modification in the php file.