|
Post by account_disabled on Apr 28, 2024 3:32:03 GMT
缺点不能向发送方反映出接收方已经正确收到的所有分组的信息。报文段的首部格式 虽然是面向字节流的但 传送的数据单元是报文段。个 报文段分为首部和数据两部分而 的全部功能都体现在它首部中各字段的作用。因此只有弄清 首部各字段的作用才能掌握 的工作原理 报文段首部的前 个字节是固定的 序号 在个 连接中传送的字节流中的每个字节都按顺序编号。整个要传送的字节流的起始序号必须在连接建立时设置。首部中的序号段所发送的数据的第个字节的序号。确认号 占 字节是期望收到对方下个报文段的第个数据字节的序号 例如 正确收到了 发送过来的个报文段其序号字段值是 而数据长度是 字节 序号 这表明 正确收到了 发送的到序号 为止的数据。 因此 期望收到 的下个数据序号是 于是 在发送给 的确认报文段中把确认号置为。请注意现在的确认号不是 也不是 而是。若确认号 则表明到序号 为止的所有数据都已正确收到。数据偏移 占 位它指出 报文段的数据起始处 新加坡电报数据库 距离 报文段的起始处有多远 紧急 当 时表明紧急指针字段有效它告诉系统此报文段中有紧急数据应尽快传送 相当于高优先级的数据 而不是按原来的排队顺序来传送。确认 仅当 时确认号字段才有效。当 时确认号无效。规定在连接建立后所有传送的报文段都必须把 置 推送 复位 当 时表明 连接中共出现严重差错 同步 在连接建立时用来同步序号。当 而 表明这是个连接请求报文段。对方若同意建立连接则应在响应的报文段中使 和。 因此 置为 就表示这是个连接请求或连接接受报文。终止 用来释放个连接。当 时表明此报文的发送方的数据已发送完毕并要求释放运输连接。窗口 占 字节。窗口值 之间的整数。窗口指的是发送本报文段中的方的接受窗口 而不是自己的发送窗口。窗口值告诉对方从本报文段首部中的确认号算起接收方目前允许对方发送的数据量。窗口值作为接收方让发送方设置其发送窗口的依据 例如发送了个报文段其确认号是 窗口字段是 这就是告诉对方 从 号算起我 即发送此报文段的方 的接受缓存空间还可接收 个字节数据 字节序号是 你在给我发送数据时必须考虑到这点。窗口字段明确指出了现在允许对方发送的数据量。窗口值经常在动态变化着。
|
|