计算机网络实验Word文档格式.docx
《计算机网络实验Word文档格式.docx》由会员分享,可在线阅读,更多相关《计算机网络实验Word文档格式.docx(9页珍藏版)》请在冰豆网上搜索。
don’tyetbeginpacketcapture).Enter“http”(justtheletters,notthequotation
marks)inthedisplay-filter-specificationwindow,sothatonlycapturedHTTP
messageswillbedisplayedlaterinthepacket-listingwindow.(We’reonly
interestedintheHTTPprotocolhere,anddon’twanttoseetheclutterofall
capturedpackets).
3.Waitabitmorethanoneminute(we’llseewhyshortly),andthenbegin
Wiresharkpacketcapture.
4.Enterthefollowingtoyourbrowser
http:
//gaia.cs.umass.edu/wireshark-labs/HTTP-wireshark-file1.html
Yourbrowsershoulddisplaytheverysimple,one-lineHTMLfile.
5.StopWiresharkpacketcapture.
实验截图如下:
1.IsyourbrowserrunningHTTPversion1.0or1.1?
WhatversionofHTTPistheserverrunning?
我的浏览器上运行的HTTP版本是1.1,在版本为的HTTP服务器上运行。
2.Whatlanguages(ifany)doesyourbrowserindicatethatitcanaccepttothe
server?
表明可以接受的语言是:
3.WhatistheIPaddressofyourcomputer?
Ofthegaia.cs.umass.eduserver?
我的计算机的IP地址是:
10.2.137.18,gaia.cs.umass.edu服务器是:
128.119.245.12。
4.Whatisthestatuscodereturnedfromtheservertoyourbrowser?
5.WhenwastheHTMLfilethatyouareretrievinglastmodifiedattheserver?
6.Howmanybytesofcontentarebeingreturnedtoyourbrowser?
7.Byinspectingtherawdatainthepacketcontentwindow,doyouseeanyheaders
withinthedatathatarenotdisplayedinthepacket-listingwindow?
Ifso,name
one
以下网页可得:
Congratulations.You'
vedownloadedthefilehttp:
//gaia.cs.umass.edu/wireshark-labs/HTTP-wireshark-file1.html!
2.TheHTTPCONDITIONALGET/responseinteraction
•StartuptheWiresharkpacketsniffer
•EnterthefollowingURLintoyourbrowser
//gaia.cs.umass.edu/wireshark-labs/HTTP-wireshark-file2.html
Yourbrowsershoulddisplayaverysimplefive-lineHTMLfile.
•QuicklyenterthesameURLintoyourbrowseragain(orsimplyselecttherefresh
buttononyourbrowser)
•StopWiresharkpacketcapture,andenter“http”inthedisplay-filter-specification
window,sothatonlycapturedHTTPmessageswillbedisplayedlaterinthe
packet-listingwindow.
•(Note:
IfyouareunabletorunWiresharkonalivenetworkconnection,youcan
usethehttp-ethereal-trace-2packettracetoanswerthequestionsbelow;
see
footnote1.Thistracefilewasgatheredwhileperformingthestepsaboveonone
oftheauthor’scomputers.)
8.InspectthecontentsofthefirstHTTPGETrequestfromyourbrowsertothe
server.Doyouseean“IF-MODIFIED-SINCE”lineintheHTTPGET?
没有看到。
9.Inspectthecontentsoftheserverresponse.Didtheserverexplicitlyreturnthe
contentsofthefile?
Howcanyoutell?
10.NowinspectthecontentsofthesecondHTTPGETrequestfromyourbrowserto
theserver.Doyouseean“IF-MODIFIED-SINCE:
”lineintheHTTPGET?
If
so,whatinformationfollowsthe“IF-MODIFIED-SINCE:
”header?
有,
11.WhatistheHTTPstatuscodeandphrasereturnedfromtheserverinresponseto
thissecondHTTPGET?
Didtheserverexplicitlyreturnthecontentsofthefile?
Explain.
304notmodified
Cache里已有不会再返回内容
3.RetrievingLongDocuments
Inourexamplesthusfar,thedocumentsretrievedhavebeensimpleandshortHTML
files.Let’snextseewhathappenswhenwedownloadalongHTMLfile.Dothe
following:
•Startupyourwebbrowser,andmakesureyourbrowser’scacheiscleared,as
discussedabove.
//gaia.cs.umass.edu/wireshark-labs/HTTP-wireshark-file3.html
YourbrowsershoulddisplaytheratherlengthyUSBillofRights.
window,sothatonlycapturedHTTPmessageswillbedisplayed.
usethehttp-ethereal-trace-3packettracetoanswerthequestionsbelow;
12.HowmanyHTTPGETrequestmessagesweresentbyyourbrowser?
1个
13.Howmanydata-containingTCPsegmentswereneededtocarrythesingleHTTP
response?
4
14.WhatisthestatuscodeandphraseassociatedwiththeresponsetotheHTTPGET
request?
200ok
Favicon.con
15.ArethereanyHTTPstatuslinesinthetransmitteddataassociatedwithaTCP-induced“Continuation”?
No,新版本整合了所有数据包内容
4.HTMLDocumentswithEmbeddedObjects
16.HowmanyHTTPGETrequestmessagesweresentbyyourbrowser?
Towhich
InternetaddressesweretheseGETrequestssent?
三个基本页:
128.119.245.12
图片1:
165.193.140.14
图片
17.Canyoutellwhetheryourbrowserdownloadedthetwoimagesserially,or
whethertheyweredownloadedfromthetwowebsitesinparallel?
Explain.
并行,两个页面是连续请求,并没有等待第一个请求得到回复才继续第二次请求
5HTTPAuthentication
18.Whatistheserver’sresponse(statuscodeandphrase)inresponsetotheinitial
HTTPGETmessagefromyourbrowser?
19.Whenyourbrowser’ssendstheHTTPGETmessageforthesecondtime,what
newfieldisincludedintheHTTPGETmessage?
计算机网络实验报告
WiresharkLab:
HTTP
班级:
2010级计科4班
学号:
41012162
姓名:
汪波