还需要论述一下seq、ack表示什么意思,应该以什么样的角度去理解这两个序列号。

  • sequence number:表示的是我方(发送方)这边,这个packet的数据部分的第一位应该在整个data stream中所在的位置。(注意这里使用的是“应该”。因为对于没有数据的传输,如ACK,虽然它有一个seq,但是这次传输在整个data stream中是不占位置的。所以下一个实际有数据的传输,会依旧从上一次发送ACK的数据包的seq开始)
  • acknowledge number:表示的是期望的对方(接收方)的下一次sequence number是多少。
  • 注意,SYN/FIN的传输虽然没有data,但是会让下一次传输的packet seq增加一,但是,ACK的传输,不会让下一次的传输packet加一。

上面这几条原则第一次读会有些抽象,可以先继续往下读分析过程,再回过头来查看这个三个原则。

http响应数据比较大时, tcp包会分成很多块, 分很多次传输。

四次挥手,断开连接

https://superuser.com/questions/204861/why-a-single-tcp-packet-gets-split-to-multiple-pdu-units-here

I presume you are referring to visible frames in the range 56-78.
Lets tackle things in this order,

  1. About: "TCP segment of a reassembled PDU"
    This implies that wireshark (ethereal?) reassembled TCP Segments together for your view.
    So, you can ignore this string, it means no harm.
    I have elaborated what these frames are in point 4 below.
  2. About: Different frames with the same 'seq' number.
    Frames 58, 60,62,64,etc show the same sequence number.
    However, note that these are not a single packet "marked as separate packets" -- no splitting.
    These packets had only the 'ACK' flag set and you will see that the ACK number is incrementing.
    These are ACKs sent to the HTTP server from your machine as different TCP segments reached it.
  3. The 'ACK' sequence starts at 1 in frame 52 and ends with 9646 in the FIN frame 78.
    During this time, all frames from your browser towards the HTTP server are repeating the last sequence number sent (which is 609) -- this is normal TCP protocol behavior.
    The browser is not sending any further data after its first HTTP request (frame 52).
    The HTTP server acknowledged this in frame 54.
  4. I expect frame 54 is the (wireshark) re-assembled server response which was formed with the frames marked "TCP segment of a reassembled PDU".
    So, all those succeeding frames marked that way are from the HTTP server to the client
    (that detail is not visible in your picture since you scrubbed the Source and Destination columns).

If you re-check your original capture file, you should find frames 54 to 67 that have TCP Source port 80 (for HTTP) will add up to the 9646 byte response data from the HTTP server.

What you see here is a 9KB reply from the HTTP server reaching your browser as several MTU limited TCP segments, each of which was acknowledged by the TCP stack of your OS.

This is the high-level sequence of communication.

  1. Your browser started connection to the HTTP server with a 3-way TCP handshake.
  2. It sent a single HTTP Request to the server on this connection
  3. The server replied to this with a 9 KB response which was spread over several TCP/IP packets as (TCP Segments)
  4. The TCP/IP stack on your browser machine acknowledged each TCP packet as it was received from the server
  5. Finally, it closed the connection starting with a FIN packet.
    I expect there were a couple of more FIN and ACK packets after frame 78 (or a single RSTpacket).

You can read up some more on Wireshark TCP Reassembly handling at the Wireshark Wiki.

tcp/ip协议中的SYN, ACK的数值变化的更多相关文章

  1. TCP/IP协议中backlog参数

    TCP建立连接是要进行三次握手,但是否完成三次握手后,服务器就处理(accept)呢? backlog其实是一个连接队列,在Linux内核2.2之前,backlog大小包括半连接状态和全连接状态两种队 ...

  2. TCP之三:TCP/IP协议中backlog参数(队列参数)

    目录: <TCP洪水攻击(SYN Flood)的诊断和处理> <TCP/IP协议中backlog参数> TCP建立连接是要进行三次握手,但是否完成三次握手后,服务器就处理(ac ...

  3. 【转】TCP/IP协议中TCP和UDP的区别

    TCP协议与UDP协议的区别    首先咱们弄清楚,TCP协议和UCP协议与TCP/IP协议的联系,很多人犯糊涂了,一直都是说TCP/IP协议与UDP协议的区别,我觉得这是没有从本质上弄清楚网络通信! ...

  4. TCP/IP 协议中的编址

    TCP/IP协议的互联网需要用到四个级别的地址:物理地址.逻辑地址.端口地址和特定应用地址 一.物理地址 物理地址称为链路地址,是由接点所在的局域网或广域网为该结点指定的地址. 这种地址的长度和格式随 ...

  5. [转]使用wireshark分析TCP/IP协议中TCP包头的格式

    本文简单介绍了TCP面向连接理论知识,详细讲述了TCP报文各个字段含义,并从Wireshark俘获分组中选取TCP连接建立相关报文段进行分析. 一.概述 TCP是面向连接的可靠传输协议,两个进程互发数 ...

  6. TCP/IP协议中几个缩写词的含义 MSL、TTL和RTT 报文最大生存时间 跳数(即生存时间) cs往返时间 MSL要大于TTL知道为什么吗?

    MSL.TTL和RTT简介 1.MSL是Maximum Segment Lifetime英文的缩写,中文可以译为“报文最大生存时间”,他是任何报文在网络上存在的最长时间,超过这个时间报文将被丢弃.因为 ...

  7. TCP/IP 协议中的滑动窗口

    一个例子明白发送缓冲区.接受缓冲区.滑动窗口协议之间的关系. 在上面的几篇文章中简单介绍了上述几个概念在TCP网络编程中的关系,也对应了几个基本socket系统调用的几个行为,这里再列举一个例子,由于 ...

  8. TCP/IP协议中的UDP与TCP的区别

    TCP面向连接,UDP面向非连接即发送数据前不需要建立链接TCP提供可靠的服务(数据传输),UDP无法保证,它没有TCP的接受确认.窗口等机制,因此也不需要交换控制信息:发生丢包也一概不负责.TCP面 ...

  9. TCP/IP协议中网关和子网掩码概念

    网关: 不同网段的IP是不能直接互通的,需要一个设备来转发,这个设备就是网关,一般就是路由器,那么路由器的地址就是网关地址. 比如192.168.2.31要往192.168.3.31发送一条消息,他们 ...

随机推荐

  1. 20169211《Linux内核原理与分析》第一周作业

          本科期间,学校开设过linux相关的课程,当时的学习方式主要以课堂听授为主.虽然老师也提供了相关的学习教材跟参考材料,但是整体学下来感觉收获并不是太大,现在回想起来,主要还是由于自己课下没 ...

  2. Django 和 html

    下面是对应的形式,自定义的forms

  3. hp

    命令组成hpacucli [parameter=value] 查看: 查看所有控制器状态 hpacucli ctrl all show 查看slot 0阵列信息详细状态 (可以查看物理磁盘和逻辑磁盘的 ...

  4. HDU2874【倍增、ST】

    题目链接[https://vjudge.net/problem/HDU-2874] 题意: 输入一个森林,总节点不超过N(N<10000),由C次询问(C<1000000),每次询问两个点 ...

  5. 【UOJ #110】【APIO 2015】Bali Sculptures

    http://uoj.ac/problem/110 这道题subtask4和subtask5是不同的算法. 主要思想都是从高位到低位贪心确定答案. 对于subtask4,n比较小,设\(f(i,j)\ ...

  6. [CodeForces-513E2]Subarray Cuts

    题目大意: 给你一个数列,从中选出k个互不重叠的非空子串,定义s[i]为第i个子串的和,求|s[1]-s[2]|+|s[2]-s[3]|+...+|s[k-1]-s[k]|的最大值. 思路: 考虑将绝 ...

  7. 【洛谷】P1176: 路径计数2【递推】

    P1176 路径计数2 题目描述 一个N×N的网格,你一开始在(1,1),即左上角.每次只能移动到下方相邻的格子或者右方相邻的格子,问到达(N,N),即右下角有多少种方法. 但是这个问题太简单了,所以 ...

  8. LCA(倍增在线算法) codevs 2370 小机房的树

    codevs 2370 小机房的树 时间限制: 1 s  空间限制: 256000 KB  题目等级 : 钻石 Diamond 题目描述 Description 小机房有棵焕狗种的树,树上有N个节点, ...

  9. bzoj4753 最佳团体

    题目描述 JSOI 信息学代表队一共有 NN 名候选人,这些候选人从 11 到 NN 编号.方便起见,JYY 的编号是 00 号.每个候选人都由一位编号比他小的候选人R_iRi​ 推荐.如果 R_i ...

  10. noip200204过河卒

    如图,A 点有一个过河卒,需要走到目标 B 点.卒行走规则:可以向下.或者向右.同时在棋盘上的任一点有一个对方的马(如上图的C点),该马所在的点和所有跳跃一步可达的点称为对方马的控制点.例如上图 C ...