通信网原理实验报告记录EthernetandARP.docx

上传人:b****5 文档编号:6921261 上传时间:2023-01-12 格式:DOCX 页数:14 大小:1.16MB
下载 相关 举报
通信网原理实验报告记录EthernetandARP.docx_第1页
第1页 / 共14页
通信网原理实验报告记录EthernetandARP.docx_第2页
第2页 / 共14页
通信网原理实验报告记录EthernetandARP.docx_第3页
第3页 / 共14页
通信网原理实验报告记录EthernetandARP.docx_第4页
第4页 / 共14页
通信网原理实验报告记录EthernetandARP.docx_第5页
第5页 / 共14页
点击查看更多>>
下载资源
资源描述

通信网原理实验报告记录EthernetandARP.docx

《通信网原理实验报告记录EthernetandARP.docx》由会员分享,可在线阅读,更多相关《通信网原理实验报告记录EthernetandARP.docx(14页珍藏版)》请在冰豆网上搜索。

通信网原理实验报告记录EthernetandARP.docx

通信网原理实验报告记录EthernetandARP

通信网原理实验报告记录EthernetandARP

 

 

————————————————————————————————作者:

————————————————————————————————日期:

 

实验一EthernetandARP

一、实验目的

1.加强对以太网帧格式的理解;

2.理解ARP协议的工作原理。

二、实验环境

1.PC机一台;

2.WireShark软件。

三、实验内容

1.CapturingandanalyzingEthernetframes

2.TheAddressResolutionProtocol

四、实验步骤及思考

(一)CapturingandanalyzingEthernetframes

(1)BasedonthecontentsoftheEthernetframecontainingtheHTTPGETmessage

1.Whatisthe48-bitEthernetaddressofyourcomputer?

Answer:

The48-bitEthernetaddressofmycomputeris:

c8:

0a:

a9:

db:

9b:

f3

2.Whatisthe48-bitdestinationaddressintheEthernetframe?

IsthistheEthernetaddressofgaia.cs.umass.edu?

(Hint:

theanswerisno).WhatdevicehasthisasitsEthernetaddress?

[Note:

thisisanimportantquestion,andonethatstudentssometimesgetwrong.Re-readpages468-469inthetextandmakesureyouunderstandtheanswerhere.]

Answer:

1)The48-bitdestinationaddressintheEthernetframeis:

00:

23:

89:

8d:

50:

71

2)ThisisnottheEthernetaddressofgaia.cs.umass.edu.

3)ItistheaddressofmyLinksysrouter,whickisthelinkusedtogetoffthesubnet.

3.Givethehexadecimalvalueforthetwo-byteFrametypefield.Whatdothebit(s)whosevalueis1meanwithintheflagfield?

Answer:

1)Thehexadecimalvalueforthetwo-byteFrametypefieldis:

ox0800

2)Thevalueis1withintheflagfieldmeansthefragmenthasnotbeenfragmented.

4.HowmanybytesfromtheverystartoftheEthernetframedoestheASCII“G”in“GET”appearintheEthernetframe?

Answer:

1)TheASCII“G”appears54bytesfromtheverystartoftheEthernetframe.

2)Calculationprocessasfollows:

Thereare14bytesofEthernetframe,20bytesofIPheaderand20bytesofTCPheaderbeforeHTTPdataisencountered.

5.WhatisthehexadecimalvalueoftheCRCfieldinthisEthernetframe?

Answer:

1)ThereisnoCRCfield.

2)BecausetheCRCcalculatedbeforetheWiresharkpacketsnifferstartup.

(2)BasedonthecontentsoftheEthernetframecontainingthefirstbyteoftheHTTPresponsemessage

6.WhatisthevalueoftheEthernetsourceaddress?

Isthistheaddressofyourcomputer,orofgaia.cs.umass.edu(Hint:

theanswerisno).WhatdevicehasthisasitsEthernetaddress?

Answer:

1)ThevalueoftheEthernetsourceaddressis:

00:

23:

89:

8d:

50:

71

2)Thisisneithertheaddressofyourcomputer,northeaddressofgaia.cs.umass.edu.

3)ItistheaddressofmyLinksysrouter,whichisthelinkusedtogetontomysubnet.

7.WhatisthedestinationaddressintheEthernetframe?

IsthistheEthernetaddressofyourcomputer?

Answer:

1)ThedestinationaddressintheEthernetframeis:

c8:

0a:

a9:

db:

9b:

f3

2)Itistheaddressofmycomputer.

(The48-bitEthernetaddressofmycomputeris:

c8:

0a:

a9:

db:

9b:

f3)

8.Givethehexadecimalvalueforthetwo-byteFrametypefield.Whatdothebit(s)whosevalueis1meanwithintheflagfield?

Answer:

1)Thehexadecimalvalueforthetwo-byteFrametypefieldis:

0x0800.

2)Thevalueis1withintheflagfieldmeansthefragmenthasnotbeenfragmented.

9.HowmanybytesfromtheverystartoftheEthernetframedoestheASCII“O”in“OK”(i.e.,theHTTPresponsecode)appearintheEthernetframe?

Answer:

1)TheASCII“O”appears54bytesfromtheverystartoftheEthernetframe.

2)Calculationprocessasfollows:

Thereare14bytesofEthernetframe,20bytesofIPheaderand20bytesofTCPheaderbeforeHTTPdataisencountered.

10.WhatisthehexadecimalvalueoftheCRCfieldinthisEthernetframe?

Answer:

1)ThereisnoCRCfield.

2)Thereason:

BecausetheCRCcalculatedbeforetheWiresharkpacketsnifferstartup.

(二)TheAddressResolutionProtocol

(1)ARPCaching

11.Writedownthecontentsofyourcomputer’sARPcache.Whatisthemeaningofeachcolumnvalue?

Answer:

1)TheInternetAddresscolumncontainstheIPaddress,.

2)ThePhysicalAddresscolumncontainstheMACaddress,andthetypeindicatestheprotocoltype.

3)ObservingARPinaction

12.WhatarethehexadecimalvaluesforthesourceanddestinationaddressesintheEthernetframecontainingtheARPrequestmessage?

Answer:

1)ThehexadecimalvaluesforthesourceaddressesintheEthernetframecontainingtheARPrequestmessageis:

00:

23:

89:

8d:

50:

71

2)ThedestinationaddressesintheEthernetframecontainingtheARPrequestmessageis:

ff:

ff:

ff:

ff:

ff:

ff

13.Givethehexadecimalvalueforthetwo-byteEthernetFrametypefield.Whatdothebit(s)whosevalueis1meanwithintheflagfield?

Answer:

Thehexadecimalvalueforthetwo-byteEthernetFrametypefieldis:

0x0806.

14.DownloadtheARPspecificationfromftp:

//ftp.rfc-editor.org/innotes/std/std37.txt.Areadable,detaileddiscussionofARPisalsoathttp:

//www.erg.abdn.ac.uk/users/gorry/course/inet-pages/arp.html.

a)HowmanybytesfromtheverybeginningoftheEthernetframedoestheARPopcodefieldbegin?

Answer:

TheARPopcodefieldbegins20bytesfromtheverybeginningoftheEthernetframe.

b)WhatisthevalueoftheopcodefieldwithintheARP-payloadpartoftheEthernetframeinwhichanARPrequestismade?

Answer:

ThehexvalueforopcodefieldwithingtheARP-payloadoftherequestis1.

c)DoestheARPmessagecontaintheIPaddressofthesender?

Answer:

Yes,theARPmessagecontaingtheIPaddress192.168.1.105forthesender.

d)WhereintheARPrequestdoesthe“question”appear–theEthernetaddressofthemachinewhosecorrespondingIPaddressisbeingqueried?

Answer:

Thefield“TargetMACaddress”issetto00:

00:

00:

00:

00:

00toquestionthemachinewhosecorrespondingIPaddress(192.168.1.105)isbeingqueried.

15.NowfindtheARPreplythatwassentinresponsetotheARPrequest.

a)HowmanybytesfromtheverybeginningoftheEthernetframedoestheARPopcodefieldbegin?

Answer:

TheARPopcodefieldbegins20bytesfromtheverybeginningoftheEthernetframe.

b)WhatisthevalueoftheopcodefieldwithintheARP-payloadpartoftheEthernetframeinwhichanARPresponseismade?

Answer:

ThehexvalueforopcodefieldwithingtheARP-payloadpartoftheEthernetframeis2.

c)WhereintheARPmessagedoesthe“answer”totheearlierARPrequestappear–theIPaddressofthemachinehavingtheEthernetaddresswhosecorrespondingIPaddressisbeingqueried?

Answer:

TheanswertotheearlierARPrequestappearsinthe”SenderMACaddress”field,whichcontainstheEthernetaddress00:

d0:

59:

a9:

3d:

68forthesenderwithIPaddress192.168.1.1.

16.WhatarethehexadecimalvaluesforthesourceanddestinationaddressesintheEthernetframecontainingtheARPreplymessage?

Answer:

Thehexvalueforthesourceaddressis00:

06:

25:

da:

af:

73andforthedestinationis00:

d0:

59:

a9:

3d:

68.

17.Opentheethernet-ethereal-trace-1tracefilein

http:

//gaia.cs.umass.edu/wireshark-labs/wireshark-traces.zip.ThefirstandsecondARPpacketsinthistracecorrespondtoanARPrequestsentbythecomputerrunningWireshark,andtheARPreplysenttothecomputerrunningWiresharkbythecomputerwiththeARP-requestedEthernetaddress.Butthereisyetanothercomputeronthisnetwork,asindiatedbypacket6–anotherARPrequest.WhyistherenoARPreply(sentinresponsetotheARPrequestinpacket6)inthepackettrace?

Answer:

Thereisnoreplyinthistrace,becausewearenotatthemachinethatsenttherequest.TheARPrequestisbroadcast,buttheARPreplyissentbackdirectlytothesender’sEthernetaddress.

五、实验结论

1.CRC在WireShark中是不能被抓到的,原因是CRC在抓包之前已经被计算好。

2.ARPRequest消息的Type字段值为1;ARPReplyt消息的Type字段值为2。

3.MACaddress是唯一的。

4.清空ARP缓存时(ARP–d)会出现如下的情况:

5.ARP–a可以查看ARP缓存中的内容。

六、实验总结

通过这次实验,我对ARP协议有了进一步的理解,在实验过程中遇到了许多问题,但经过查阅资料并和学姐交流,最终解决了这些问题,以实验的方式验证课本上的理论知识,学习也变得更有意义。

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 工作范文

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1