TCP实验报告
更新时间:2024-06-15 08:25:01 阅读量: 综合文库 文档下载
“TCP/IP技术与应用”
实 验 报 告
实验一 HTTP报文分析
一、实验目的
? 熟悉HTTP的报文格式 ? 熟练Ethereal的使用方法
二、实验环境
? Windows操作系统 ? Ethereal协议分析仪
三、试验要求
1. Basic HTTP GET/response interaction
Open and examine the Ethereal captured packet file http-ethereal-trace-1, and then answer the following questions.
1) Is your browser running HTTP version 1.0 or 1.1? What version of HTTP is the server running? HTTP/1.1,HTTP/1.1
2) What languages (if any) does your browser indicate that it can accept to the server?
Answer:
3) What is the IP address of your computer? Of the gaia.cs.umass.edu server? Answer:192.168.1.102 63.240.76.19
4) What is the status code returned from the server to your browser?
Answer:200 HTTP/1.1 200 OK(text/html) 404 HTTP/1.1 404 Not Found(text/html)
5) When was the HTML file that you are retrieving last modified at the server?
Answer: 6) How many bytes of content are being returned to your browser?
Answer:
7) By inspecting the raw data in the packet content window, do you see any headers within the data
that are not displayed in the packet-listing window? If so, name one.
Answer: Yes
2. The HTTP CONDITIONAL GET/response interaction
Open and examine the Ethereal captured packet file http-ethereal-trace-2, and then answer the following questions.
8) Inspect the contents of the first HTTP GET request from your browser to the server. Do you see an
“IF-MODIFIED-SINCE” line in the HTTP GET? Answer: No
9) Inspect the contents of the server response. Did the server explicitly return the contents of the file?
How can you tell? Answer: Yes,
10) 10. Now inspect the contents of the second HTTP GET request from your browser to the server.
Do you see an “IF-MODIFIED-SINCE:” line in the HTTP GET? If so, what information follows the “IF-MODIFIED-SINCE:” header?
Answer: Yes. Date after Tue,23 Sep 2003 05:35:00 GMT
11) What is the HTTP status code and phrase returned from the server in response to this second HTTP
GET? Did the server explicitly return the contents of the file? Explain. Answer:
NO,因为第一次访问后已经返回,第二次申请时未变
3. Retrieving Long Documents
Open and examine the Ethereal captured packet file http-ethereal-trace-3, and then answer the following questions.
12) How many HTTP GET request messages were sent by your browser? Answer:1
13) How many data-containing TCP segments were needed to carry the single HTTP response?
Answer:4
14) What is the status code and phrase associated with the response to the HTTP GET request? Answer:
15) Are there any HTTP status lines in the transmitted data associated with a TCP induced
“Continuation”? Answer: NO
4. HTML Documents with Embedded Objects
Open and examine the Ethereal captured packet file http-ethereal-trace-4, and then answer the following questions.
16) How many HTTP GET request messages were sent by your browser? To which Internet
addresses were these GET requests sent? Answer: 3,
17) Can you tell whether your browser downloaded the two images serially, or whether they were
downloaded from the two web sites in parallel? Explain.
Answer: Parallel,因为第一次请求图片,未等到回复就继续第二次申请
试验二 TCP 报文分析
一、实验目的
? 熟悉TCP的报文格式 ? 熟练Ethereal的使用方法
二、实验环境
? Windows操作系统 ? Ethereal协议分析仪
三、试验要求
Open and examine the Ethereal captured packet file tcp-ethereal-trace-1, and then answer the following questions.
1. What is the IP address and TCP port number used by the client computer (source) that is
transferring the file to gaia.cs.umass.edu? Answer:
TCP segments for this connection? Answer:
2. What is the IP address of gaia.cs.umass.edu? On what port number is it sending and receiving
3. What is the sequence number of the TCP SYN segment that is used to initiate the TCP
connection between the client computer and gaia.cs.umass.edu? What is it in the segment that identifies the segment as a SYN segment? Answer:0,Flags中SYN为1
4. What is the sequence number of the SYNACK segment sent by gaia.cs.umass.edu to the client
computer in reply to the SYN? What is the value of the ACKnowledgement field in the SYNACK segment? How did gaia.cs.umass.edu determine that value? What is it in the segment that identifies the segment as a SYNACK segment? Answer:
因为上一次seq=0 由Flags中SYN与ACK位为1
5. What is the sequence number of the TCP segment containing the HTTP POST command?
Answer:
6. Consider the TCP segment containing the HTTP POST as the first segment in the TCP
connection. What are the sequence numbers of the first six segments in the TCP connection (including the segment containing the HTTP POST)? At what time was each segment sent? When was the ACK for each segment received? Answer: 编号 1 2 3 4 5 6
7. What is the length of each of the first six TCP segments?
(相对)序列号 1 566 2026 3486 4946 6406 发送时间 0.026477 确认时间 TCP报文长度 585 1480 1480 1480 1480 1480 Answer:585 1480 1480 1480 1480 1480
8. What is the minimum amount of available buffer space advertised at the received for the entire trace?
Answer: 5840
9. How much data does the receiver typically acknowledge in an ACK? Can you identify cases where the receiver is ACKing every other received segment Answer:2个.能
10. What is the throughput (bytes transferred per unit time) for the TCP connection? Explain how
you calculated this value?
Answer:163411/(5.297341-0.041737)
实验三 TCP/IP报文综合分析
一、实验目的
? 熟悉TCP的报文格式 ? 熟练Ethereal的使用方法
二、实验环境
? Windows操作系统 ? Ethereal协议分析仪
三、实验内容及要求
用Ethereal打开文件http-ethereal-trace-1,分析12号分组的原始数据,并回答以下问题:(注: 有X栏不用填写)
1、Ethernet报文 字段名 起止字节地址 内容(十六进制) 意义 00-0d X X Ethernet报头 Source MAC Dest. MAC Type 06-0b 00-05 0c-0d 源物理地址 目标物理地址 协议为IP 0800 2、IP报文 字段名 IP报头 Protocol 3、TCP报文 字段名 TCP报头 Windows size
起止字节地址 0e-21 17-17 内容(十六进制) X 06 意义 X 协议为TCP 起止字节地址 22-35 30-31 内容(十六进制) X 1920 意义 X 接收窗口6432字节
4、HTTP报文 字段名 Status line Head lines Entity body
起止字节地址 36-46 内容(十六进制) 意义 版本http/1.1 状态吗200 短语ok X X 47-16b 16e-1b6 X X 5、该分组到达目标机后,执行什么操作?产生的效果是什么? Answer:
实验四 Socket编程及应用
一、试验目的
? ?
了解Socket编程方法。 熟悉Socket应用。
二、实验环境
? Windows操作系统 ? Ethereal协议分析仪 ? VC++
三、试验内容
1、分析socket应用程序
2、网上聊天
(1)用Ethereal捕获报文。 (2)用socket软件聊天。
(3)分析聊天内容与TCP/IP协议关系。
3、简单浏览器
(1)用Ethereal捕获报文。
(2)以socket软件作为浏览器,编制请求报文。 (3)请求报文发往:192.168.1.20 (4)分析响应报文。
三、实验报告要求 1、网上聊天
? 聊天内容 Hi,guo! Hi,du!
? 源IP地址、目标IP地址是什么? 原:192.168.0.139 ,目:192.168.0.140 ? 传输层协议、端口号是什么? TCP,2000
? 应用层协议是什么? Answer:无
?
应用层报文是什么? Answer:无
2、简单浏览器
?
输入的请求报文什么? Answer: GET /hll.html HTTP/1.1
Host: 192.168.0.250
? 收到的响应报文什么? Answer:
Hello Everyone !
? 应用层协议是什么? Answer:HTTP
正在阅读:
TCP实验报告06-15
阅读理解--高考精品班理科综合寒假特训班辅导《英语》第一章第一节讲义108-11
办公室企业文化标语03-16
Auto CAD机械制图基础教程04-22
整车物流运输规划方案08-14
开利风冷热泵模块机组方案书模板 - 图文04-04
民族宗教年度工作总结参考范文08-16
- 多层物业服务方案
- (审判实务)习惯法与少数民族地区民间纠纷解决问题(孙 潋)
- 人教版新课标六年级下册语文全册教案
- 词语打卡
- photoshop实习报告
- 钢结构设计原理综合测试2
- 2014年期末练习题
- 高中数学中的逆向思维解题方法探讨
- 名师原创 全国通用2014-2015学年高二寒假作业 政治(一)Word版
- 北航《建筑结构检测鉴定与加固》在线作业三
- XX县卫生监督所工程建设项目可行性研究报告
- 小学四年级观察作文经典评语
- 浅谈110KV变电站电气一次设计-程泉焱(1)
- 安全员考试题库
- 国家电网公司变电运维管理规定(试行)
- 义务教育课程标准稿征求意见提纲
- 教学秘书面试技巧
- 钢结构工程施工组织设计
- 水利工程概论论文
- 09届九年级数学第四次模拟试卷
- 实验
- 报告
- TCP
- 程序与算法综合设计课程设计指导书
- 超静定次数的确定及基本结构的取法
- 2016年第一季度安全管理工作总结
- 普定县化处镇中心学校教育信息化应用典型案例
- 16级6班2017年上学期期中考试语文试题
- 电大小企业管理本科问答题已排版
- RFID在食品追溯管理中的应用
- 大学会计专业学年论文选题
- 学习心得
- 2FSK调制与解调电路
- 多媒体技术实验指导
- 精品完整版XXX市疾病预防控制中心工程施工组织设计 - 图文
- C#作业参考答案
- 韦达定理
- 阜新发电厂乏汽余热利用工程可行性研究报告 - 图文
- 蚂蚁与蚜虫
- 2011年高考试题——英语(重庆卷)精校版含答案
- 中国消化系统药物行业市场前景分析预测年度报告(目录) - 图文
- 中药制剂检测技术试题库
- 1-10知识点