通信网原理实验报告TCP

  1. 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
  2. 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
  3. 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。

实验一TCP

一、实验目的

1.熟悉TCP协议的基本原理

2.利用WireShark对TCP协议进行分析

二、实验环境

1.PC机一台;

2.WireShark软件。

三、实验内容

1. Capturing a bulk TCP transfer from your computer to a remote

server

2. A first look at the captured trace

四、实验步骤

(一)1. Capturing a bulk TCP transfer from your computer to a remote server

(1)启动浏览器,打开/ethereal-labs/alice.txt网页,得到ALICE'S ADVENTURES IN WONDERLAND文本,将该文件保存到主机上。

(2)打开/ethereal-labs/TCP-ethereal-file1.html (3)窗口如下图所示。在Browse按钮旁的文本框中输入文件ALICE'S ADVENTURES IN WONDERLAND的路径

(4)启动Ethereal,开始分组捕获。

(5)在浏览器中,单击“Upload alice.txt file”按钮,将文件上传到服务器,文件上传完毕,一个简短的贺词信息跳出浏览器窗口。

(6)停止分组捕获,结果如下所示

2. A first look at the captured trace

在显示筛选规则编辑框中输入“tcp”,可以看到在本地主机和服务器之间传输的一系列tcp和HTTP消息,我们可以看到包含SYN Segment的三次握手。也可以看到有主机向服务器发送的一个HTTP POST消息和一系列的“http continuation”报文,如下图所示:

3. TCP congestion control in action

在Ethereal已捕获分组列表子窗口中选择一个TCP 报文段。选择菜单:Statistics->TCP Stream Graph-> Time-Sequence-Graph(Stevens)。会看到如下所示的图:

五、实验思考

1. What is the IP address and TCP port number used by your client computer(source) to transfer the file to ? What is the IP address and port number used by to receive the file.

Answer:client computer(source) IP address: 115.157.220.91 TCP port number: 62705 (destination)Ip address: 128.119.245.12 TCP port number: 80

2. What is the sequence number of the TCP SYN segment that is used to initiate the TCP connection between the client computer and ? What is it in the segment that identifies the segment as a SYN segment?

Answer:The sequence number of the TCP SYN segment is 0 to initiate the TCP connection between the client computer。

The SYN flag is set to 1 and it indicates that this segment is a SYN segment.

3. What is the sequence number of the SYNACK segment sent by to the client computer in reply to the SYN? What is the value of the ACKnowledgement field in the SYNACK segment? How did determine that value? What is it in the segment that identifies the segment as a SYNACK segment?

Answer:

1)Sequence number of the SYNACK segment from is 0 in this trace.

2)The value of the ACKnowledgement field in the SYNACK segment is 1.

3)The value of the ACKnowledgement field in the SYNACK segment is

determined by by adding 1 to the initial sequence number of SYN segment from the client computer.

4)The SYN flag and Acknowledgement flag in the segment are set to 1 and they indicate that this segment is a SYNACK segment.

4. What is the sequence number of the TCP segment containing the HTTP POST command? Note that in order to find the POST command, you’ll need to dig into the packet content field at the bottom of the Ethereal window, looking for a segment with a “POST”within its DATA field.

Answer:No. 173 segment is the TCP segment containing the HTTP POST command. The sequence number of this segment is 1.

相关文档
最新文档